add Costants to Storage ServiceEndpoint coordinates
This commit is contained in:
parent
81a3481faa
commit
496e4d05f4
|
@ -51,8 +51,8 @@ public class Configuration {
|
||||||
private static final String HL_CONTEXT = "/d4science.research-infrastructures.eu";
|
private static final String HL_CONTEXT = "/d4science.research-infrastructures.eu";
|
||||||
private static final String HL_CONTEXT_DEV = "/gcube";
|
private static final String HL_CONTEXT_DEV = "/gcube";
|
||||||
private static final String HL_CONTEXT_PRE = "/pred4s";
|
private static final String HL_CONTEXT_PRE = "/pred4s";
|
||||||
|
protected static final String STORAGE_SERVICEENDPOINT_NAME="StorageManager";
|
||||||
|
protected static final String STORAGE_SERVICEENDPOINT_CATEGORY="Storage";
|
||||||
/**
|
/**
|
||||||
* Loads all the configuration parameters in a java object
|
* Loads all the configuration parameters in a java object
|
||||||
* @param sc: service class of the remote resource
|
* @param sc: service class of the remote resource
|
||||||
|
|
|
@ -63,7 +63,7 @@ public class ISClientConnector {
|
||||||
ScopeProvider.instance.set(scope);
|
ScopeProvider.instance.set(scope);
|
||||||
}
|
}
|
||||||
SimpleQuery query = queryFor(ServiceEndpoint.class);
|
SimpleQuery query = queryFor(ServiceEndpoint.class);
|
||||||
query.addCondition("$resource/Profile/Category/text() eq 'Storage' and $resource/Profile/Name eq 'StorageManager' ");
|
query.addCondition("$resource/Profile/Category/text() eq '"+Configuration.STORAGE_SERVICEENDPOINT_CATEGORY+"' and $resource/Profile/Name eq '"+Configuration.STORAGE_SERVICEENDPOINT_NAME+"' ");
|
||||||
DiscoveryClient<ServiceEndpoint> client = clientFor(ServiceEndpoint.class);
|
DiscoveryClient<ServiceEndpoint> client = clientFor(ServiceEndpoint.class);
|
||||||
List<ServiceEndpoint> resources = client.submit(query);
|
List<ServiceEndpoint> resources = client.submit(query);
|
||||||
if(scope!=null){
|
if(scope!=null){
|
||||||
|
|
Loading…
Reference in New Issue