some fixes
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/Common/resource-registry-handlers@146644 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
3bc5e7b9df
commit
3407a40547
|
@ -316,6 +316,9 @@ public class EServiceManager extends ApplicationLifecycleHandler {
|
||||||
} catch (ResourceAlreadyPresentException e) {
|
} catch (ResourceAlreadyPresentException e) {
|
||||||
ResourceRegistryClient registryClient = ResourceRegistryClientFactory.create();
|
ResourceRegistryClient registryClient = ResourceRegistryClientFactory.create();
|
||||||
eService = registryClient.getInstance(EService.class, eService.getHeader().getUUID());
|
eService = registryClient.getInstance(EService.class, eService.getHeader().getUUID());
|
||||||
|
String state = applicationContext.lifecycle().state().remoteForm().toLowerCase();
|
||||||
|
logger.debug("Moving app {} to {}", applicationContext.name(), state);
|
||||||
|
createOrUpdateServiceStateFacet(eService, state);
|
||||||
} catch (ResourceAvailableInAnotherContextException e) {
|
} catch (ResourceAvailableInAnotherContextException e) {
|
||||||
// Adding the HostingNode I also add the EService thanks to propagationConstraint
|
// Adding the HostingNode I also add the EService thanks to propagationConstraint
|
||||||
addHostingNodeToCurrentContext();
|
addHostingNodeToCurrentContext();
|
||||||
|
|
|
@ -290,6 +290,7 @@ public class HostingNodeManager extends ContainerHandler {
|
||||||
hostingNode = registryClient.getInstance(
|
hostingNode = registryClient.getInstance(
|
||||||
HostingNode.class, hostingNode.getHeader()
|
HostingNode.class, hostingNode.getHeader()
|
||||||
.getUUID());
|
.getUUID());
|
||||||
|
updateHostingNode(hostingNode);
|
||||||
} catch (ResourceAvailableInAnotherContextException e) {
|
} catch (ResourceAvailableInAnotherContextException e) {
|
||||||
addToContext(hostingNode, token);
|
addToContext(hostingNode, token);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue