1 package org.openecomp.datarouter.policy;
3 import java.io.FileNotFoundException;
5 import org.onap.aai.datarouter.entity.DocumentStoreDataEntity;
7 public class EntityEventPolicyStubbed extends EntityEventPolicy {
10 public EntityEventPolicyStubbed(EntityEventPolicyConfig config) throws FileNotFoundException {
15 protected void handleSearchServiceOperation(DocumentStoreDataEntity eventEntity, String action, String index) {
16 //Stub out the actual call to Search Data service and instead store/update documents in memory
18 switch (action.toLowerCase()) {
20 InMemorySearchDatastore.put(eventEntity.getId(), eventEntity.getAsJson()); // they are executed if variable == c1
23 InMemorySearchDatastore.put(eventEntity.getId(), eventEntity.getAsJson()); // they are executed if variable == c1
26 InMemorySearchDatastore.remove(eventEntity.getId()); // they are executed if variable == c1
31 } catch (Exception ex) {