moved to jakarta

This commit is contained in:
lucio 2024-03-12 17:28:51 +01:00
parent dd5d5073ed
commit ba36a1da87
12 changed files with 171 additions and 166 deletions

View File

@ -1,5 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<classpath> <classpath>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="src" output="target/classes" path="src/main/java"> <classpathentry kind="src" output="target/classes" path="src/main/java">
<attributes> <attributes>
<attribute name="optional" value="true"/> <attribute name="optional" value="true"/>
@ -13,14 +23,17 @@
<attribute name="test" value="true"/> <attribute name="test" value="true"/>
</attributes> </attributes>
</classpathentry> </classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"> <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources">
<attributes> <attributes>
<attribute name="maven.pomderived" value="true"/> <attribute name="maven.pomderived" value="true"/>
<attribute name="optional" value="true"/>
</attributes> </attributes>
</classpathentry> </classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER"> <classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources">
<attributes> <attributes>
<attribute name="maven.pomderived" value="true"/> <attribute name="maven.pomderived" value="true"/>
<attribute name="test" value="true"/>
<attribute name="optional" value="true"/>
</attributes> </attributes>
</classpathentry> </classpathentry>
<classpathentry kind="output" path="target/classes"/> <classpathentry kind="output" path="target/classes"/>

51
pom.xml
View File

@ -7,9 +7,12 @@
<version>1.0.1-SNAPSHOT</version> <version>1.0.1-SNAPSHOT</version>
<name>Legacy is publisher</name> <name>Legacy is publisher</name>
<scm> <scm>
<connection>scm:git:https://code-repo.d4science.org/gCubeSystem/legacy-is-publisher-connector</connection> <connection>
<developerConnection>scm:git:https://code-repo.d4science.org/gCubeSystem/legacy-is-publisher-connector</developerConnection> scm:git:https://code-repo.d4science.org/gCubeSystem/legacy-is-publisher-connector</connection>
<url>https://code-repo.d4science.org/gCubeSystem/legacy-is-publisher-connector</url> <developerConnection>
scm:git:https://code-repo.d4science.org/gCubeSystem/legacy-is-publisher-connector</developerConnection>
<url>
https://code-repo.d4science.org/gCubeSystem/legacy-is-publisher-connector</url>
</scm> </scm>
<properties> <properties>
<maven.compiler.source>11</maven.compiler.source> <maven.compiler.source>11</maven.compiler.source>
@ -25,13 +28,35 @@
<dependency> <dependency>
<groupId>org.gcube.distribution</groupId> <groupId>org.gcube.distribution</groupId>
<artifactId>gcube-smartgears-bom</artifactId> <artifactId>gcube-smartgears-bom</artifactId>
<version>3.0.0</version> <version>3.0.1-SNAPSHOT</version>
<type>pom</type> <type>pom</type>
<scope>import</scope> <scope>import</scope>
</dependency> </dependency>
</dependencies> </dependencies>
</dependencyManagement> </dependencyManagement>
<dependencies> <dependencies>
<dependency>
<groupId>jakarta.xml.bind</groupId>
<artifactId>jakarta.xml.bind-api</artifactId>
</dependency>
<dependency>
<groupId>org.glassfish.jaxb</groupId>
<artifactId>jaxb-runtime</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-impl</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>jakarta.xml.ws</groupId>
<artifactId>jakarta.xml.ws-api</artifactId>
</dependency>
<dependency>
<groupId>jakarta.servlet</groupId>
<artifactId>jakarta.servlet-api</artifactId>
</dependency>
<dependency> <dependency>
<groupId>org.slf4j</groupId> <groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId> <artifactId>slf4j-api</artifactId>
@ -56,22 +81,6 @@
<groupId>org.gcube.resources</groupId> <groupId>org.gcube.resources</groupId>
<artifactId>common-gcore-resources</artifactId> <artifactId>common-gcore-resources</artifactId>
</dependency> </dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>4.0.1</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.sun.xml.ws</groupId>
<artifactId>jaxws-rt</artifactId>
<version>2.3.3</version>
<type>pom</type>
</dependency>
<dependency>
<groupId>com.sun.xml.ws</groupId>
<artifactId>rt</artifactId>
<version>2.3.3</version>
</dependency>
</dependencies> </dependencies>
</project> </project>

View File

@ -25,8 +25,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
@SmartgearsProfilePublisher @SmartgearsProfilePublisher
public class LegacyISPublisher implements Publisher{ public class LegacyISPublisher implements Publisher {
private static Logger logger = LoggerFactory.getLogger(LegacyISPublisher.class); private static Logger logger = LoggerFactory.getLogger(LegacyISPublisher.class);
@ -34,7 +33,6 @@ public class LegacyISPublisher implements Publisher{
private static Map<String, Resource> resourcesCache = new HashMap<String, Resource>(); private static Map<String, Resource> resourcesCache = new HashMap<String, Resource>();
@Override @Override
public boolean create(ContainerContext container, Set<String> contexts) { public boolean create(ContainerContext container, Set<String> contexts) {
ContainerProfileBuilder cpb = new ContainerProfileBuilder(container); ContainerProfileBuilder cpb = new ContainerProfileBuilder(container);
@ -43,36 +41,30 @@ public class LegacyISPublisher implements Publisher{
synchronized (resourcesCache) { synchronized (resourcesCache) {
String id = container.id(); String id = container.id();
if (!resourcesCache.containsKey(id)) if (!resourcesCache.containsKey(id))
hostingNode = cpb.create(); hostingNode = cpb.create();
else { else {
hostingNode = (HostingNode) resourcesCache.get(id); hostingNode = (HostingNode) resourcesCache.get(id);
cpb.update(hostingNode); cpb.update(hostingNode);
} }
for (String context: contexts) for (String context : contexts)
ResourceMediator.setScope(hostingNode, context); ResourceMediator.setScope(hostingNode, context);
resourcesCache.put(id, hostingNode); resourcesCache.put(id, hostingNode);
} }
for (String context : filterICContexts(hostingNode.scopes().asCollection())) {
logger.info("publishing container in context {}", context);
AuthorizedTasks.executeSafely(() -> {
try {
registry.getStubs().create(toXml(hostingNode), hostingNode.type().toString());
} catch (Throwable e) {
logger.error("error publishing container in context {}", context, e);
}
for (String context : filterICContexts(hostingNode.scopes().asCollection())) }, new ICSecret(context));
try { }
logger.info("publishing container in context {}", context);
AuthorizedTasks.executeSafely( () -> {
try {
registry.getStubs().create(toXml(hostingNode), hostingNode.type().toString());
}catch (Exception e) {
logger.error("error publishing container", e);
throw new RuntimeException(e);
}
}, new ICSecret(context));
}catch (Throwable e) {
logger.error("error publishing container in context {}", context, e);
}
return true; return true;
} }
@ -83,34 +75,29 @@ public class LegacyISPublisher implements Publisher{
synchronized (resourcesCache) { synchronized (resourcesCache) {
String id = application.id(); String id = application.id();
if (!resourcesCache.containsKey(id)) if (!resourcesCache.containsKey(id))
endpoint = cpb.create(); endpoint = cpb.create();
else { else {
endpoint = (GCoreEndpoint) resourcesCache.get(id); endpoint = (GCoreEndpoint) resourcesCache.get(id);
} }
for (String context: contexts) for (String context : contexts)
ResourceMediator.setScope(endpoint, context); ResourceMediator.setScope(endpoint, context);
resourcesCache.put(id, endpoint); resourcesCache.put(id, endpoint);
} }
for (String context : filterICContexts(endpoint.scopes().asCollection())) for (String context : filterICContexts(endpoint.scopes().asCollection())) {
try { logger.info("publishing application in context {}", context);
logger.info("publishing application in context {}", context); AuthorizedTasks.executeSafely(() -> {
AuthorizedTasks.executeSafely(() -> { try {
try { String resource = toXml(endpoint);
String resource = toXml(endpoint); registry.getStubs().create(resource, endpoint.type().toString());
registry.getStubs().create(resource, endpoint.type().toString()); } catch (Throwable e) {
}catch (Exception e) { logger.error("error publishing application in {}", context, e);
logger.error("error publishing application", e); }
throw new RuntimeException(e); }, new ICSecret(context));
} }
}, new ICSecret(context));
}catch (Throwable e) {
logger.error("error publishing application profile in context {}", context, e);
}
return true; return true;
} }
@ -122,14 +109,14 @@ public class LegacyISPublisher implements Publisher{
synchronized (resourcesCache) { synchronized (resourcesCache) {
String id = container.id(); String id = container.id();
if (!resourcesCache.containsKey(id)) if (!resourcesCache.containsKey(id))
hostingNode = cpb.create(); hostingNode = cpb.create();
else { else {
hostingNode = (HostingNode) resourcesCache.get(id); hostingNode = (HostingNode) resourcesCache.get(id);
cpb.update(hostingNode); cpb.update(hostingNode);
} }
for (String context: contexts) for (String context : contexts)
ResourceMediator.removeScope(hostingNode, context); ResourceMediator.removeScope(hostingNode, context);
resourcesCache.put(id, hostingNode); resourcesCache.put(id, hostingNode);
@ -138,31 +125,31 @@ public class LegacyISPublisher implements Publisher{
for (String context : contexts) for (String context : contexts)
if (isCompatibleScopeForRemove(hostingNode, context)) if (isCompatibleScopeForRemove(hostingNode, context))
try { try {
AuthorizedTasks.executeSafely( () -> { AuthorizedTasks.executeSafely(() -> {
try { try {
logger.info("removing container from context {}", context); logger.info("removing container from context {}", context);
registry.getStubs().remove(hostingNode.id(),hostingNode.type().toString()); registry.getStubs().remove(hostingNode.id(), hostingNode.type().toString());
}catch (Exception e) { } catch (Throwable e) {
throw new RuntimeException(e); throw new RuntimeException(e);
} }
}, new ICSecret(context)); }, new ICSecret(context));
}catch (Throwable e) { } catch (Throwable e) {
logger.error("error removing container in context {}", context, e); logger.error("error removing container in context {}", context, e);
} }
for (String context : filterICContexts(hostingNode.scopes().asCollection())) for (String context : filterICContexts(hostingNode.scopes().asCollection()))
try { try {
logger.info("updating container in context {}", context); logger.info("updating container in context {}", context);
AuthorizedTasks.executeSafely( () -> { AuthorizedTasks.executeSafely(() -> {
try { try {
registry.getStubs().update(hostingNode.id(), hostingNode.type().toString(),toXml(hostingNode)); registry.getStubs().update(hostingNode.id(), hostingNode.type().toString(), toXml(hostingNode));
}catch (Exception e) { } catch (Throwable e) {
throw new RuntimeException(e); throw new RuntimeException(e);
} }
}, new ICSecret(context)); }, new ICSecret(context));
}catch (Throwable e) { } catch (Throwable e) {
logger.error("error updating container in context {}", context, e); logger.error("error updating container in context {}", context, e);
} }
@ -177,47 +164,47 @@ public class LegacyISPublisher implements Publisher{
synchronized (resourcesCache) { synchronized (resourcesCache) {
String id = application.id(); String id = application.id();
if (!resourcesCache.containsKey(id)) if (!resourcesCache.containsKey(id))
endpoint = cpb.create(); endpoint = cpb.create();
else { else {
endpoint = (GCoreEndpoint) resourcesCache.get(id); endpoint = (GCoreEndpoint) resourcesCache.get(id);
} }
for (String context: contexts) for (String context : contexts)
ResourceMediator.removeScope(endpoint, context); ResourceMediator.removeScope(endpoint, context);
resourcesCache.put(id, endpoint); resourcesCache.put(id, endpoint);
} }
//TODO: Review this // TODO: Review this
for (String context : contexts) for (String context : contexts)
if (isCompatibleScopeForRemove(endpoint, context)) if (isCompatibleScopeForRemove(endpoint, context))
try { try {
AuthorizedTasks.executeSafely( () -> { AuthorizedTasks.executeSafely(() -> {
try { try {
logger.info("removing container in context {}", context); logger.info("removing container in context {}", context);
registry.getStubs().remove(endpoint.id(),endpoint.type().toString()); registry.getStubs().remove(endpoint.id(), endpoint.type().toString());
}catch (Exception e) { } catch (Throwable e) {
throw new RuntimeException(e); throw new RuntimeException(e);
} }
}, new ICSecret(context)); }, new ICSecret(context));
}catch (Throwable e) { } catch (Throwable e) {
logger.error("error removing container in context {}", context, e); logger.error("error removing container in context {}", context, e);
} }
for (String context : filterICContexts(endpoint.scopes().asCollection())) for (String context : filterICContexts(endpoint.scopes().asCollection()))
try { try {
AuthorizedTasks.executeSafely(() -> { AuthorizedTasks.executeSafely(() -> {
try { try {
logger.info("updating application in context {}", context); logger.info("updating application in context {}", context);
String resource = toXml(endpoint); String resource = toXml(endpoint);
registry.getStubs().update(endpoint.id(), endpoint.type().toString(), resource); registry.getStubs().update(endpoint.id(), endpoint.type().toString(), resource);
}catch (Exception e) { } catch (Throwable e) {
throw new RuntimeException(e); throw new RuntimeException(e);
} }
}, new ICSecret(context)); }, new ICSecret(context));
}catch (Throwable e) { } catch (Throwable e) {
logger.error("error updating application profile in context {}", context, e); logger.error("error updating application profile in context {}", context, e);
} }
@ -226,27 +213,24 @@ public class LegacyISPublisher implements Publisher{
@Override @Override
public boolean update(ApplicationContext application) { public boolean update(ApplicationContext application) {
GCoreEndpoint endpoint; GCoreEndpoint endpoint;
synchronized (resourcesCache) { synchronized (resourcesCache) {
String id = application.id(); String id = application.id();
endpoint = (GCoreEndpoint) resourcesCache.get(id); endpoint = (GCoreEndpoint) resourcesCache.get(id);
} }
for (String context : filterICContexts(endpoint.scopes().asCollection())) for (String context : filterICContexts(endpoint.scopes().asCollection())) {
try { logger.info("updating application in context {}", context);
logger.info("updating application in context {}", context); AuthorizedTasks.executeSafely(() -> {
AuthorizedTasks.executeSafely(() -> { try {
try { String resource = toXml(endpoint);
String resource = toXml(endpoint); registry.getStubs().update(endpoint.id(), endpoint.type().toString(), resource);
registry.getStubs().update(endpoint.id(), endpoint.type().toString(), resource); } catch (Throwable e) {
}catch (Exception e) { logger.error("error updating application profile in context {}", context, e);
throw new RuntimeException(e); }
} }, new ICSecret(context));
}, new ICSecret(context)); }
}catch (Throwable e) {
logger.error("error updating application profile in context {}", context, e);
}
return true; return true;
} }
@ -265,86 +249,85 @@ public class LegacyISPublisher implements Publisher{
resourcesCache.put(id, hostingNode); resourcesCache.put(id, hostingNode);
} }
for (String context : filterICContexts(hostingNode.scopes().asCollection())) for (String context : filterICContexts(hostingNode.scopes().asCollection())) {
try { logger.info("updating container in context {}", context);
logger.info("updating container in context {}", context); AuthorizedTasks.executeSafely(() -> {
AuthorizedTasks.executeSafely( () -> { try {
try { logger.info("updating container in context {}", context);
logger.info("updating container in context {}", context); registry.getStubs().update(hostingNode.id(), hostingNode.type().toString(), toXml(hostingNode));
registry.getStubs().update(hostingNode.id(), hostingNode.type().toString(),toXml(hostingNode)); } catch (Throwable e) {
}catch (Exception e) { logger.error("error updating container in context {}", context, e);
throw new RuntimeException(e); }
}
}, new ICSecret(context)); }, new ICSecret(context));
}catch (Throwable e) { }
logger.error("error updating container in context {}", context, e);
}
return true; return true;
} }
private String toXml(Resource resource){ private String toXml(Resource resource) {
StringWriter writer = new StringWriter(); StringWriter writer = new StringWriter();
Resources.marshal(resource, writer); Resources.marshal(resource, writer);
return writer.toString(); return writer.toString();
} }
private Set<String> filterICContexts(Collection<String> contexts){ private Set<String> filterICContexts(Collection<String> contexts) {
return contexts.stream().map( (c) ->{ return contexts.stream().map((c) -> {
ContextBean bean = new ContextBean(c); ContextBean bean = new ContextBean(c);
return bean.is(Type.VRE)? bean.enclosingScope().toString(): c; return bean.is(Type.VRE) ? bean.enclosingScope().toString() : c;
}).collect(Collectors.toSet()); }).collect(Collectors.toSet());
} }
private <T extends Resource> boolean isCompatibleScopeForRemove(T resource, String scope){ private <T extends Resource> boolean isCompatibleScopeForRemove(T resource, String scope) {
if(resource.scopes().size() == 0) if (resource.scopes().size() == 0)
return true; return true;
if(new ContextBean(scope).is(Type.VRE)) if (new ContextBean(scope).is(Type.VRE))
return !anotherBrotherVREOrVOOnResource(resource, scope); return !anotherBrotherVREOrVOOnResource(resource, scope);
else if(new ContextBean(scope).is(Type.VO)) else if (new ContextBean(scope).is(Type.VO))
return !anotherSonVREOnResource(resource, scope); return !anotherSonVREOnResource(resource, scope);
else else
return !anotherInfraScopeOnResource(resource, scope); return !anotherInfraScopeOnResource(resource, scope);
} }
private <T extends Resource> boolean anotherBrotherVREOrVOOnResource(T resource, String scope){ private <T extends Resource> boolean anotherBrotherVREOrVOOnResource(T resource, String scope) {
if(!new ContextBean(scope).is(Type.VRE)) if (!new ContextBean(scope).is(Type.VRE))
throw new IllegalArgumentException("anotherBrotherVREOrVOOnResource method: the input scope must be a VRE scope"); throw new IllegalArgumentException(
String enclosedScope=new ContextBean(scope).enclosingScope().toString(); "anotherBrotherVREOrVOOnResource method: the input scope must be a VRE scope");
for(String s : resource.scopes()){ String enclosedScope = new ContextBean(scope).enclosingScope().toString();
if (isChildScope(enclosedScope, s) || for (String s : resource.scopes()) {
((enclosedScope != null) && (enclosedScope.toString().equals(s)))) if (isChildScope(enclosedScope, s) || ((enclosedScope != null) && (enclosedScope.toString().equals(s))))
return true; return true;
} }
return false; return false;
} }
private <T extends Resource> boolean anotherSonVREOnResource(T resource, String scope){ private <T extends Resource> boolean anotherSonVREOnResource(T resource, String scope) {
if(!new ContextBean(scope).is(Type.VO)) if (!new ContextBean(scope).is(Type.VO))
throw new IllegalArgumentException("anotherSonVREOnResource method: the input scope must be a VO scope"); throw new IllegalArgumentException("anotherSonVREOnResource method: the input scope must be a VO scope");
for(String s : resource.scopes()){ for (String s : resource.scopes()) {
if(isChildScope(scope, s)) if (isChildScope(scope, s))
return true; return true;
} }
return false; return false;
} }
private boolean isChildScope(String fatherScope, String sonScope) { private boolean isChildScope(String fatherScope, String sonScope) {
ContextBean currentEnclosedScope=new ContextBean(sonScope).enclosingScope(); ContextBean currentEnclosedScope = new ContextBean(sonScope).enclosingScope();
return (currentEnclosedScope != null) && (currentEnclosedScope.toString().equals(fatherScope)); return (currentEnclosedScope != null) && (currentEnclosedScope.toString().equals(fatherScope));
} }
private <T extends Resource> boolean anotherInfraScopeOnResource(T resource, String scope){ private <T extends Resource> boolean anotherInfraScopeOnResource(T resource, String scope) {
if(!new ContextBean(scope).is(Type.INFRASTRUCTURE)) if (!new ContextBean(scope).is(Type.INFRASTRUCTURE))
throw new IllegalArgumentException("anotherInfraScopeOnResource method: the input scope must be a INFRASTRUCTURE scope"); throw new IllegalArgumentException(
String infraScopeFound=null; "anotherInfraScopeOnResource method: the input scope must be a INFRASTRUCTURE scope");
for(String s : resource.scopes()){ String infraScopeFound = null;
while(new ContextBean(s).enclosingScope() != null) for (String s : resource.scopes()) {
s=new ContextBean(s).enclosingScope().toString(); while (new ContextBean(s).enclosingScope() != null)
infraScopeFound=s; s = new ContextBean(s).enclosingScope().toString();
if(infraScopeFound.equals(scope)) infraScopeFound = s;
if (infraScopeFound.equals(scope))
return true; return true;
} }

View File

@ -24,8 +24,6 @@ public class Registry {
private List<URI> endpoints; private List<URI> endpoints;
private static final Logger log = LoggerFactory.getLogger(Registry.class); private static final Logger log = LoggerFactory.getLogger(Registry.class);
public List<URI> getEndPoints(){ public List<URI> getEndPoints(){
String scope=SecretManagerProvider.get().getContext(); String scope=SecretManagerProvider.get().getContext();
@ -46,24 +44,25 @@ public class Registry {
.setResult("$resource/Profile/AccessPoint/RunningInstanceInterfaces/Endpoint[string(@EntryName) eq '"+RegistryConstants.service_entrypoint+"']/string()"); .setResult("$resource/Profile/AccessPoint/RunningInstanceInterfaces/Endpoint[string(@EntryName) eq '"+RegistryConstants.service_entrypoint+"']/string()");
endpoints = client.submit(query); endpoints = client.submit(query);
if (endpoints.size()==0){ if (endpoints.size()==0){
throw new IllegalArgumentException("No registry endpoint founded"); throw new IllegalArgumentException("No endpoint for registry found");
} }
// able/disable cache
cache.put(scope, endpoints); cache.put(scope, endpoints);
} }
return endpoints; return endpoints;
} }
public RegistryStub getStubs() throws RegistryNotFoundException{ public RegistryStub getStubs() throws RegistryNotFoundException{
String context=SecretManagerProvider.get().getContext();
URI endpoint=null; URI endpoint=null;
//use another method to cache epr //use another method to cache epr
endpoint = getEndPoints().get(0); endpoint = getEndPoints().get(0);
log.debug("get stubs from endpoint: "+ endpoint); log.debug("get stubs in context {} from endpoint {} ", context, endpoint);
return stubFor(RegistryConstants.registry).at(endpoint); return stubFor(RegistryConstants.registry).at(endpoint);
} }
public RegistryStub getStubs(URI endpoint) throws RegistryNotFoundException{ public RegistryStub getStubs(URI endpoint) throws RegistryNotFoundException{
log.debug("get stubs from endpoint: "+ endpoint); String context=SecretManagerProvider.get().getContext();
log.debug("get stubs in context {} from fixed endpoint {} ", context, endpoint);
return stubFor(RegistryConstants.registry).at(endpoint); return stubFor(RegistryConstants.registry).at(endpoint);
} }

View File

@ -5,7 +5,7 @@ import java.util.Arrays;
import java.util.Calendar; import java.util.Calendar;
import java.util.List; import java.util.List;
import javax.servlet.ServletRegistration; import jakarta.servlet.ServletRegistration;
import org.gcube.common.resources.gcore.GCoreEndpoint; import org.gcube.common.resources.gcore.GCoreEndpoint;
import org.gcube.smartgears.configuration.ProxyAddress; import org.gcube.smartgears.configuration.ProxyAddress;

View File

@ -1,11 +1,7 @@
package org.gcube.common.core.publisher.is.legacy.stubs; package org.gcube.common.core.publisher.is.legacy.stubs;
import static org.gcube.common.core.publisher.is.legacy.stubs.RegistryConstants.*; import static org.gcube.common.core.publisher.is.legacy.stubs.RegistryConstants.portType;
import static org.gcube.common.core.publisher.is.legacy.stubs.RegistryConstants.target_namespace;
import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebResult;
import javax.jws.WebService;
import org.gcube.common.core.publisher.is.legacy.stubs.fault.CreateException; import org.gcube.common.core.publisher.is.legacy.stubs.fault.CreateException;
import org.gcube.common.core.publisher.is.legacy.stubs.fault.InvalidResourceException; import org.gcube.common.core.publisher.is.legacy.stubs.fault.InvalidResourceException;
@ -14,6 +10,11 @@ import org.gcube.common.core.publisher.is.legacy.stubs.fault.ResourceDoesNotExis
import org.gcube.common.core.publisher.is.legacy.stubs.fault.ResourceNotAcceptedException; import org.gcube.common.core.publisher.is.legacy.stubs.fault.ResourceNotAcceptedException;
import org.gcube.common.core.publisher.is.legacy.stubs.fault.UpdateException; import org.gcube.common.core.publisher.is.legacy.stubs.fault.UpdateException;
import jakarta.jws.WebMethod;
import jakarta.jws.WebParam;
import jakarta.jws.WebResult;
import jakarta.jws.WebService;
/** /**
* A local interface to the resource discovery service. * A local interface to the resource discovery service.
* *

View File

@ -1,10 +1,10 @@
package org.gcube.common.core.publisher.is.legacy.stubs.fault; package org.gcube.common.core.publisher.is.legacy.stubs.fault;
import javax.xml.ws.WebFault;
import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub; import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub;
import jakarta.xml.ws.WebFault;
/** /**
* Thrown by {@link RegistryStub#create(String, String)} when something is failed on creation * Thrown by {@link RegistryStub#create(String, String)} when something is failed on creation
*/ */

View File

@ -1,9 +1,9 @@
package org.gcube.common.core.publisher.is.legacy.stubs.fault; package org.gcube.common.core.publisher.is.legacy.stubs.fault;
import javax.xml.ws.WebFault;
import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub; import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub;
import jakarta.xml.ws.WebFault;
/** /**
* Thrown by {@link RegistryStub#create(String, String)} when the resource type is invalid * Thrown by {@link RegistryStub#create(String, String)} when the resource type is invalid
* service. * service.

View File

@ -1,9 +1,9 @@
package org.gcube.common.core.publisher.is.legacy.stubs.fault; package org.gcube.common.core.publisher.is.legacy.stubs.fault;
import javax.xml.ws.WebFault;
import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub; import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub;
import jakarta.xml.ws.WebFault;
/** /**
* Thrown by {@link RegistryStub#remove(String, String)} when something is failed on remove * Thrown by {@link RegistryStub#remove(String, String)} when something is failed on remove
*/ */

View File

@ -1,9 +1,9 @@
package org.gcube.common.core.publisher.is.legacy.stubs.fault; package org.gcube.common.core.publisher.is.legacy.stubs.fault;
import javax.xml.ws.WebFault;
import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub; import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub;
import jakarta.xml.ws.WebFault;
/** /**
* Thrown by {@link RegistryStub#remove(String, String)} when the resource does not exist in the collector * Thrown by {@link RegistryStub#remove(String, String)} when the resource does not exist in the collector
*/ */

View File

@ -2,10 +2,10 @@ package org.gcube.common.core.publisher.is.legacy.stubs.fault;
import javax.xml.ws.WebFault;
import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub; import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub;
import jakarta.xml.ws.WebFault;
/** /**
* Thrown by {@link RegistryStub#create(String, String)} when the resource is not accepted cause it doesn't satisfy a requirement * Thrown by {@link RegistryStub#create(String, String)} when the resource is not accepted cause it doesn't satisfy a requirement
*/ */

View File

@ -1,10 +1,10 @@
package org.gcube.common.core.publisher.is.legacy.stubs.fault; package org.gcube.common.core.publisher.is.legacy.stubs.fault;
import javax.xml.ws.WebFault;
import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub; import org.gcube.common.core.publisher.is.legacy.stubs.RegistryStub;
import jakarta.xml.ws.WebFault;
/** /**
* Thrown by {@link RegistryStub#update(String, String)} when something is failed on update * Thrown by {@link RegistryStub#update(String, String)} when something is failed on update
*/ */