Migrate to the most recent releases of gxRest, gcube-model and information-system-model. Introduce Jersey BOM.
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/resource-management/resource-manager@176875 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
54e2b6bbab
commit
f9b0ba55ce
17
pom.xml
17
pom.xml
|
@ -35,10 +35,11 @@
|
||||||
<type>pom</type>
|
<type>pom</type>
|
||||||
<scope>import</scope>
|
<scope>import</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<!-- https://mvnrepository.com/artifact/org.glassfish.jersey/jersey-bom -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.glassfish.jersey</groupId>
|
<groupId>org.glassfish.jersey</groupId>
|
||||||
<artifactId>jersey-bom</artifactId>
|
<artifactId>jersey-bom</artifactId>
|
||||||
<version>2.26-b03</version>
|
<version>2.25.1</version>
|
||||||
<type>pom</type>
|
<type>pom</type>
|
||||||
<scope>import</scope>
|
<scope>import</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
@ -55,7 +56,7 @@
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.information-system</groupId>
|
<groupId>org.gcube.information-system</groupId>
|
||||||
<artifactId>resource-registry-client</artifactId>
|
<artifactId>resource-registry-client</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -75,9 +76,8 @@
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.information-system</groupId>
|
<groupId>org.gcube.resource-management</groupId>
|
||||||
<artifactId>gcube-resources</artifactId>
|
<artifactId>gcube-model</artifactId>
|
||||||
<version>1.7.1-SNAPSHOT</version>
|
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -85,11 +85,11 @@
|
||||||
<artifactId>resource-registry-context-client</artifactId>
|
<artifactId>resource-registry-context-client</artifactId>
|
||||||
<version>2.0.0-SNAPSHOT</version>
|
<version>2.0.0-SNAPSHOT</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.common</groupId>
|
<groupId>org.gcube.common</groupId>
|
||||||
<artifactId>gxJRS</artifactId>
|
<artifactId>gxJRS</artifactId>
|
||||||
<version>1.1.0-SNAPSHOT</version>
|
<version>1.1.1-SNAPSHOT</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- jersey -->
|
<!-- jersey -->
|
||||||
|
@ -125,13 +125,12 @@
|
||||||
<version>4.11</version>
|
<version>4.11</version>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<!-- https://mvnrepository.com/artifact/org.glassfish.jersey.test-framework.providers/jersey-test-framework-provider-simple -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.glassfish.jersey.test-framework.providers</groupId>
|
<groupId>org.glassfish.jersey.test-framework.providers</groupId>
|
||||||
<artifactId>jersey-test-framework-provider-simple</artifactId>
|
<artifactId>jersey-test-framework-provider-simple</artifactId>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ch.qos.logback</groupId>
|
<groupId>ch.qos.logback</groupId>
|
||||||
<artifactId>logback-classic</artifactId>
|
<artifactId>logback-classic</artifactId>
|
||||||
|
|
|
@ -91,22 +91,17 @@
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.information-system</groupId>
|
<groupId>org.gcube.resource-management</groupId>
|
||||||
<artifactId>gcube-resources</artifactId>
|
<artifactId>gcube-model</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.common</groupId>
|
<groupId>org.gcube.common</groupId>
|
||||||
<artifactId>gxRest</artifactId>
|
<artifactId>gxJRS</artifactId>
|
||||||
<version>1.0.0-SNAPSHOT</version>
|
<version>1.1.1-SNAPSHOT</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- jersey -->
|
<!-- jersey -->
|
||||||
<dependency>
|
|
||||||
<groupId>javax.ws.rs</groupId>
|
|
||||||
<artifactId>javax.ws.rs-api</artifactId>
|
|
||||||
<version>2.1</version>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.glassfish.jersey.containers</groupId>
|
<groupId>org.glassfish.jersey.containers</groupId>
|
||||||
|
@ -137,12 +132,11 @@
|
||||||
<artifactId>resource-registry-context-client</artifactId>
|
<artifactId>resource-registry-context-client</artifactId>
|
||||||
<version>2.0.0-SNAPSHOT</version>
|
<version>2.0.0-SNAPSHOT</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- Test Dependency -->
|
<!-- Runtime Dependency -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.glassfish.jersey.media</groupId>
|
<groupId>org.glassfish.jersey.media</groupId>
|
||||||
<artifactId>jersey-media-json-jackson</artifactId>
|
<artifactId>jersey-media-json-jackson</artifactId>
|
||||||
<scope>runtime</scope>
|
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- Test Dependency -->
|
<!-- Test Dependency -->
|
||||||
|
@ -152,7 +146,7 @@
|
||||||
<version>4.11</version>
|
<version>4.11</version>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<!-- https://mvnrepository.com/artifact/org.glassfish.jersey.test-framework.providers/jersey-test-framework-provider-simple -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.glassfish.jersey.test-framework.providers</groupId>
|
<groupId>org.glassfish.jersey.test-framework.providers</groupId>
|
||||||
<artifactId>jersey-test-framework-provider-simple</artifactId>
|
<artifactId>jersey-test-framework-provider-simple</artifactId>
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package org.gcube.resourcemanagement.manager.webapp.context;
|
package org.gcube.resourcemanagement.manager.webapp.context;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.informationsystem.impl.utils.ISMapper;
|
import org.gcube.informationsystem.model.impl.utils.ISMapper;
|
||||||
import org.gcube.informationsystem.model.entity.Context;
|
import org.gcube.informationsystem.model.reference.entity.Context;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -3,8 +3,8 @@ package org.gcube.resourcemanagement.manager.webapp.context;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
|
||||||
import org.gcube.common.gxrest.response.outbound.LocalCodeException;
|
import org.gcube.common.gxrest.response.outbound.LocalCodeException;
|
||||||
import org.gcube.informationsystem.model.entity.Context;
|
import org.gcube.informationsystem.model.reference.entity.Context;
|
||||||
import org.gcube.informationsystem.model.relation.IsParentOf;
|
import org.gcube.informationsystem.model.reference.relation.IsParentOf;
|
||||||
import org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException;
|
import org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException;
|
||||||
import org.gcube.informationsystem.resourceregistry.api.exceptions.context.ContextAlreadyPresentException;
|
import org.gcube.informationsystem.resourceregistry.api.exceptions.context.ContextAlreadyPresentException;
|
||||||
import org.gcube.resourcemanagement.manager.io.rs.RMCreateContextCode;
|
import org.gcube.resourcemanagement.manager.io.rs.RMCreateContextCode;
|
||||||
|
|
|
@ -2,8 +2,8 @@ package org.gcube.resourcemanagement.manager.webapp.context;
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
import org.gcube.informationsystem.model.entity.Context;
|
import org.gcube.informationsystem.model.reference.entity.Context;
|
||||||
import org.gcube.informationsystem.model.entity.Resource;
|
import org.gcube.informationsystem.model.reference.entity.Resource;
|
||||||
import org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException;
|
import org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException;
|
||||||
import org.gcube.informationsystem.resourceregistry.client.ResourceRegistryClient;
|
import org.gcube.informationsystem.resourceregistry.client.ResourceRegistryClient;
|
||||||
import org.gcube.informationsystem.resourceregistry.client.ResourceRegistryClientFactory;
|
import org.gcube.informationsystem.resourceregistry.client.ResourceRegistryClientFactory;
|
||||||
|
|
|
@ -12,7 +12,8 @@ import javax.ws.rs.core.Response;
|
||||||
import org.gcube.common.authorization.library.provider.CalledMethodProvider;
|
import org.gcube.common.authorization.library.provider.CalledMethodProvider;
|
||||||
import org.gcube.common.gxrest.response.outbound.GXOutboundErrorResponse;
|
import org.gcube.common.gxrest.response.outbound.GXOutboundErrorResponse;
|
||||||
import org.gcube.common.gxrest.response.outbound.GXOutboundSuccessResponse;
|
import org.gcube.common.gxrest.response.outbound.GXOutboundSuccessResponse;
|
||||||
import org.gcube.informationsystem.model.entity.Context;
|
import org.gcube.informationsystem.model.reference.entity.Context;
|
||||||
|
|
||||||
import static org.gcube.resourcemanagement.manager.io.rs.RMContextsAccess.*;
|
import static org.gcube.resourcemanagement.manager.io.rs.RMContextsAccess.*;
|
||||||
import org.gcube.resourcemanagement.manager.webapp.ResourceInitializer;
|
import org.gcube.resourcemanagement.manager.webapp.ResourceInitializer;
|
||||||
import org.gcube.resourcemanagement.manager.webapp.context.CreateRequest;
|
import org.gcube.resourcemanagement.manager.webapp.context.CreateRequest;
|
||||||
|
|
|
@ -22,9 +22,9 @@ import javax.xml.bind.Unmarshaller;
|
||||||
import org.gcube.common.authorization.library.provider.CalledMethodProvider;
|
import org.gcube.common.authorization.library.provider.CalledMethodProvider;
|
||||||
import org.gcube.common.gxrest.response.outbound.GXOutboundErrorResponse;
|
import org.gcube.common.gxrest.response.outbound.GXOutboundErrorResponse;
|
||||||
import org.gcube.common.gxrest.response.outbound.GXOutboundSuccessResponse;
|
import org.gcube.common.gxrest.response.outbound.GXOutboundSuccessResponse;
|
||||||
import org.gcube.informationsystem.impl.entity.ContextImpl;
|
import org.gcube.informationsystem.model.impl.entity.ContextImpl;
|
||||||
import org.gcube.informationsystem.impl.utils.ISMapper;
|
import org.gcube.informationsystem.model.impl.utils.ISMapper;
|
||||||
import org.gcube.informationsystem.model.entity.Context;
|
import org.gcube.informationsystem.model.reference.entity.Context;
|
||||||
import org.gcube.resourcemanagement.manager.io.rs.RMContextDoesNotExistException;
|
import org.gcube.resourcemanagement.manager.io.rs.RMContextDoesNotExistException;
|
||||||
import org.gcube.resourcemanagement.manager.webapp.ResourceInitializer;
|
import org.gcube.resourcemanagement.manager.webapp.ResourceInitializer;
|
||||||
import org.gcube.resourcemanagement.manager.webapp.context.ContextHolder;
|
import org.gcube.resourcemanagement.manager.webapp.context.ContextHolder;
|
||||||
|
|
|
@ -1,36 +1,24 @@
|
||||||
package org.gcube.resourcemanagement.manager.webapp.context;
|
package org.gcube.resourcemanagement.manager.webapp.context;
|
||||||
|
|
||||||
import static org.junit.Assert.*;
|
import static org.junit.Assert.assertEquals;
|
||||||
|
import static org.junit.Assert.assertNotNull;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.io.InputStream;
|
import java.io.InputStream;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
import javax.ws.rs.client.Entity;
|
|
||||||
import javax.ws.rs.core.Application;
|
import javax.ws.rs.core.Application;
|
||||||
import javax.ws.rs.core.MediaType;
|
|
||||||
import javax.ws.rs.core.Response;
|
import javax.ws.rs.core.Response;
|
||||||
import javax.ws.rs.core.Response.Status;
|
import javax.ws.rs.core.Response.Status;
|
||||||
import javax.ws.rs.core.Response.StatusType;
|
|
||||||
|
|
||||||
import org.gcube.common.authorization.client.Constants;
|
import org.gcube.common.authorization.client.Constants;
|
||||||
import org.gcube.common.authorization.client.exceptions.ObjectNotFound;
|
import org.gcube.common.authorization.client.exceptions.ObjectNotFound;
|
||||||
import org.gcube.common.authorization.library.AuthorizationEntry;
|
import org.gcube.common.authorization.library.AuthorizationEntry;
|
||||||
import org.gcube.common.authorization.library.provider.SecurityTokenProvider;
|
import org.gcube.common.authorization.library.provider.SecurityTokenProvider;
|
||||||
import org.gcube.common.gxrest.response.inbound.GXInboundResponse;
|
import org.gcube.common.gxrest.response.inbound.GXInboundResponse;
|
||||||
import org.gcube.common.gxrest.response.outbound.CodeFinder;
|
|
||||||
import org.gcube.common.gxrest.response.outbound.ErrorCode;
|
|
||||||
import org.gcube.common.scope.api.ScopeProvider;
|
import org.gcube.common.scope.api.ScopeProvider;
|
||||||
import org.gcube.informationsystem.impl.entity.ContextImpl;
|
|
||||||
import org.gcube.informationsystem.impl.utils.ISMapper;
|
|
||||||
import org.gcube.informationsystem.model.entity.Context;
|
|
||||||
import org.gcube.informationsystem.resourceregistry.context.ResourceRegistryContextClient;
|
|
||||||
import org.gcube.informationsystem.resourceregistry.context.ResourceRegistryContextClientImpl;
|
|
||||||
import org.gcube.resourcemanagement.manager.io.rs.RMCreateContextCode;
|
|
||||||
import org.gcube.resourcemanagement.manager.io.rs.RMContextDoesNotExistException;
|
|
||||||
import org.gcube.resourcemanagement.manager.io.rs.RMContextsAccess;
|
import org.gcube.resourcemanagement.manager.io.rs.RMContextsAccess;
|
||||||
import org.gcube.resourcemanagement.manager.webapp.rs.RMContexts;
|
|
||||||
import org.gcube.resourcemanagement.manager.webapp.rs.RMTestForGXRest;
|
import org.gcube.resourcemanagement.manager.webapp.rs.RMTestForGXRest;
|
||||||
import org.glassfish.jersey.server.ResourceConfig;
|
import org.glassfish.jersey.server.ResourceConfig;
|
||||||
import org.glassfish.jersey.test.JerseyTest;
|
import org.glassfish.jersey.test.JerseyTest;
|
||||||
|
@ -44,8 +32,6 @@ import org.junit.runners.MethodSorters;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
import com.fasterxml.jackson.core.JsonProcessingException;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Test cases for the Context methods.
|
* Test cases for the Context methods.
|
||||||
*
|
*
|
||||||
|
|
|
@ -16,7 +16,7 @@ import org.gcube.common.authorization.client.exceptions.ObjectNotFound;
|
||||||
import org.gcube.common.authorization.library.AuthorizationEntry;
|
import org.gcube.common.authorization.library.AuthorizationEntry;
|
||||||
import org.gcube.common.authorization.library.provider.SecurityTokenProvider;
|
import org.gcube.common.authorization.library.provider.SecurityTokenProvider;
|
||||||
import org.gcube.common.scope.api.ScopeProvider;
|
import org.gcube.common.scope.api.ScopeProvider;
|
||||||
import org.gcube.informationsystem.model.entity.Context;
|
import org.gcube.informationsystem.model.reference.entity.Context;
|
||||||
import org.gcube.informationsystem.resourceregistry.client.ResourceRegistryClient;
|
import org.gcube.informationsystem.resourceregistry.client.ResourceRegistryClient;
|
||||||
import org.gcube.informationsystem.resourceregistry.client.ResourceRegistryClientImpl;
|
import org.gcube.informationsystem.resourceregistry.client.ResourceRegistryClientImpl;
|
||||||
import org.gcube.informationsystem.resourceregistry.context.ResourceRegistryContextClient;
|
import org.gcube.informationsystem.resourceregistry.context.ResourceRegistryContextClient;
|
||||||
|
|
|
@ -21,9 +21,9 @@ import org.gcube.common.gxrest.response.inbound.GXInboundResponse;
|
||||||
import org.gcube.common.gxrest.response.outbound.CodeFinder;
|
import org.gcube.common.gxrest.response.outbound.CodeFinder;
|
||||||
import org.gcube.common.gxrest.response.outbound.ErrorCode;
|
import org.gcube.common.gxrest.response.outbound.ErrorCode;
|
||||||
import org.gcube.common.scope.api.ScopeProvider;
|
import org.gcube.common.scope.api.ScopeProvider;
|
||||||
import org.gcube.informationsystem.impl.entity.ContextImpl;
|
import org.gcube.informationsystem.model.impl.entity.ContextImpl;
|
||||||
import org.gcube.informationsystem.impl.utils.ISMapper;
|
import org.gcube.informationsystem.model.impl.utils.ISMapper;
|
||||||
import org.gcube.informationsystem.model.entity.Context;
|
import org.gcube.informationsystem.model.reference.entity.Context;
|
||||||
import org.gcube.informationsystem.resourceregistry.context.ResourceRegistryContextClient;
|
import org.gcube.informationsystem.resourceregistry.context.ResourceRegistryContextClient;
|
||||||
import org.gcube.informationsystem.resourceregistry.context.ResourceRegistryContextClientImpl;
|
import org.gcube.informationsystem.resourceregistry.context.ResourceRegistryContextClientImpl;
|
||||||
import org.gcube.resourcemanagement.manager.io.rs.RMCreateContextCode;
|
import org.gcube.resourcemanagement.manager.io.rs.RMCreateContextCode;
|
||||||
|
|
Loading…
Reference in New Issue