Revision ac1f29b5
Added by Cherian Mathew over 8 years ago
eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/service/CdmServiceRequestExecutor.java | ||
---|---|---|
44 | 44 |
logger.info("Remote invoking : " + currentRemoteInvocation.getMethodName() + "@" + config.getServiceUrl()); |
45 | 45 |
rir = super.doExecuteRequest(config, baos); |
46 | 46 |
if(rir.getValue() != null && !rir.hasException()) { |
47 |
if(rir.getValue() instanceof UpdateResult){ |
|
48 |
UpdateResult result = (UpdateResult)rir.getValue(); |
|
49 |
if(result.isOk()){ |
|
50 |
rir = new RemoteInvocationResult(cdmEntitySessionManager.load(result, true)); |
|
51 |
} |
|
52 |
} else { |
|
53 |
rir = new RemoteInvocationResult(cdmEntitySessionManager.load(rir.getValue(), true)); |
|
54 |
} |
|
47 |
if("merge".equals(currentRemoteInvocation.getMethodName()) || "save".equals(currentRemoteInvocation.getMethodName())) { |
|
48 |
rir = new RemoteInvocationResult(cdmEntitySessionManager.load(rir.getValue(), true)); |
|
49 |
} else if(rir.getValue() instanceof UpdateResult){ |
|
50 |
UpdateResult result = (UpdateResult)rir.getValue(); |
|
51 |
if(result.isOk()){ |
|
52 |
cdmEntitySessionManager.load(result, true); |
|
53 |
} |
|
54 |
} else { |
|
55 |
rir = new RemoteInvocationResult(cdmEntitySessionManager.load(rir.getValue(), false)); |
|
56 |
} |
|
55 | 57 |
} |
56 | 58 |
cache(currentRemoteInvocation, rir); |
57 | 59 |
} |
Also available in: Unified diff
Add method to sessionOwner objects to fine tune performance using property paths