diff --git a/src/main/java/org/gcube/contentmanager/storageclient/wrapper/ISClientConnector.java b/src/main/java/org/gcube/contentmanager/storageclient/wrapper/ISClientConnector.java index b656c4d..28140d5 100644 --- a/src/main/java/org/gcube/contentmanager/storageclient/wrapper/ISClientConnector.java +++ b/src/main/java/org/gcube/contentmanager/storageclient/wrapper/ISClientConnector.java @@ -39,6 +39,14 @@ public class ISClientConnector { protected ServiceEndpoint storageResource; public String region; private static HashMap isCache; + /** + * identify the ServiceEndpoint Category of the storage-manager backend + */ + public final String CATEGORY="DataStorage"; + /** + * identify the ServiceEndpoint name of the storage-manager backend + */ + public final String NAME="StorageManager-S3"; public ISClientConnector(String backendType){ setBackendType(backendType); @@ -71,7 +79,7 @@ public class ISClientConnector { ScopeProvider.instance.set(scope); } SimpleQuery query = queryFor(ServiceEndpoint.class); - query.addCondition("$resource/Profile/Category/text() eq 'DataStorage' and $resource/Profile/Name eq 'StorageManager' "); + query.addCondition("$resource/Profile/Category/text() eq '"+CATEGORY+"' and $resource/Profile/Name eq '"+NAME+"' "); DiscoveryClient client = clientFor(ServiceEndpoint.class); List resources = client.submit(query); if(scope!=null){