X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Forg%2Fonap%2Fcrud%2Fservice%2FCrudAsyncGraphDataService.java;h=5e264b59bd0f24ec6bac4eb743bf6f289546b403;hb=74879a7b7a5607c89aef5fa9d64aca5ddea8e3b7;hp=60a18d330691cdec78d55675e1930a0e83761020;hpb=4141124d43da1503193416a7d23fc07cec308049;p=aai%2Fgizmo.git diff --git a/src/main/java/org/onap/crud/service/CrudAsyncGraphDataService.java b/src/main/java/org/onap/crud/service/CrudAsyncGraphDataService.java index 60a18d3..5e264b5 100644 --- a/src/main/java/org/onap/crud/service/CrudAsyncGraphDataService.java +++ b/src/main/java/org/onap/crud/service/CrudAsyncGraphDataService.java @@ -84,12 +84,21 @@ public class CrudAsyncGraphDataService extends AbstractGraphDataService { public static Integer getRequestTimeOut() { return requestTimeOut; } + + public CrudAsyncGraphDataService(GraphDao dao, + EventPublisher asyncRequestPublisher, + EventConsumer asyncResponseConsumer) throws CrudException { + this(dao,dao,asyncRequestPublisher,asyncResponseConsumer); + } public CrudAsyncGraphDataService(GraphDao dao, + GraphDao daoForGet, EventPublisher asyncRequestPublisher, EventConsumer asyncResponseConsumer) throws CrudException { - super(dao); + super(); + this.dao = dao; + this.daoForGet = daoForGet; requestTimeOut = DEFAULT_REQUEST_TIMEOUT; try { @@ -261,7 +270,7 @@ public class CrudAsyncGraphDataService extends AbstractGraphDataService { public String patchVertex(String version, String id, String type, VertexPayload payload) throws CrudException { Vertex existingVertex - = dao.getVertex(id, OxmModelValidator.resolveCollectionType(version, type)); + = dao.getVertex(id, OxmModelValidator.resolveCollectionType(version, type), version); Vertex patchedVertex = OxmModelValidator.validateIncomingPatchPayload(id, version, type, payload.getProperties(), existingVertex); @@ -443,5 +452,4 @@ public class CrudAsyncGraphDataService extends AbstractGraphDataService { + " , operation: " + event.getOperation().toString() + " , result: " + response.getResult() + " , error: " + response.getErrorMessage()); } - } \ No newline at end of file