Commit fec12b22 authored by cazenave's avatar cazenave
Browse files

suite...

parent e592556b
...@@ -32,8 +32,34 @@ ...@@ -32,8 +32,34 @@
</properties> </properties>
<dependencies> <dependencies>
<!--VITAMUI --> <!--VITAMUI -->
<dependency>
<groupId>fr.gouv.vitamui.ui</groupId>
<artifactId>ui-commons</artifactId>
</dependency>
<dependency>
<groupId>fr.gouv.vitamui.commons</groupId>
<artifactId>commons-api</artifactId>
</dependency>
<dependency>
<groupId>fr.gouv.vitamui</groupId>
<artifactId>iam-commons</artifactId>
</dependency>
<dependency>
<groupId>fr.gouv.vitamui.commons</groupId>
<artifactId>commons-rest</artifactId>
</dependency>
<dependency>
<groupId>fr.gouv.vitamui</groupId>
<artifactId>iam-external-client</artifactId>
</dependency>
<dependency>
<groupId>fr.gouv.vitamui</groupId>
<artifactId>ui-frontend</artifactId>
<scope>provided</scope>
<type>pom</type>
<version>${project.version}</version>
</dependency>
<dependency> <dependency>
<groupId>fr.gouv.vitamui</groupId> <groupId>fr.gouv.vitamui</groupId>
<artifactId>ui-frontend</artifactId> <artifactId>ui-frontend</artifactId>
......
...@@ -22,25 +22,26 @@ ...@@ -22,25 +22,26 @@
package fr.cines.pac.ws; package fr.cines.pac.ws;
import java.util.HashSet; import fr.gouv.vitamui.commons.api.logger.VitamUILogger;
import java.util.Set; import fr.gouv.vitamui.commons.api.logger.VitamUILoggerFactory;
import javax.ws.rs.ApplicationPath;
import javax.ws.rs.core.Application;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication; import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder; import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.core.env.Environment; import org.springframework.core.env.Environment;
import javax.ws.rs.ApplicationPath;
import javax.ws.rs.core.Application;
/** /**
* *
* @author RACHID Sala <rachid@cines.fr> * @author RACHID Sala <rachid@cines.fr>
* *
*/ */
@SpringBootApplication
@ApplicationPath("/pastis-api") @ApplicationPath("/pastis-api")
@EnableAutoConfiguration
public class PastisRestApplication extends Application { public class PastisRestApplication extends Application {
@Autowired @Autowired
...@@ -48,20 +49,21 @@ public class PastisRestApplication extends Application { ...@@ -48,20 +49,21 @@ public class PastisRestApplication extends Application {
public PastisRestApplication(){} public PastisRestApplication(){}
private static final Logger LOGGER = LoggerFactory.getLogger(PastisRestApplication.class); // private static final Logger LOGGER = LoggerFactory.getLogger(PastisRestApplication.class);
private static final VitamUILogger LOGGER = VitamUILoggerFactory.getInstance(PastisRestApplication.class);
public static void main(final String[] args) { public static void main(final String[] args) {
SpringApplication app = new SpringApplicationBuilder(PastisRestApplication.class).properties("spring.config.name:ui-pastis-application").build(); SpringApplication app = new SpringApplicationBuilder(PastisRestApplication.class).properties("spring.config.name:ui-pastis-application").build();
app.run(args); app.run(args);
} }
public Set<Class<?>> getClasses( ) /** public Set<Class<?>> getClasses( )
{ {
final Set<Class<?>> returnValue = new HashSet<Class<?>>( ); final Set<Class<?>> returnValue = new HashSet<Class<?>>( );
returnValue.add( PastisResource.class ); returnValue.add( PastisResource.class );
return returnValue; return returnValue;
} }
**/
/** La constante LOGGER. */ /** La constante LOGGER. */
......
...@@ -34,14 +34,13 @@ ...@@ -34,14 +34,13 @@
* The fact that you are presently reading this means that you have had * The fact that you are presently reading this means that you have had
* knowledge of the CeCILL-C license and that you accept its terms. * knowledge of the CeCILL-C license and that you accept its terms.
*/ */
package pastis.config; package fr.cines.pac.ws.config;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import fr.gouv.vitamui.commons.rest.RestExceptionHandler; import fr.gouv.vitamui.commons.rest.RestExceptionHandler;
import fr.gouv.vitamui.commons.rest.configuration.SwaggerConfiguration; import fr.gouv.vitamui.commons.rest.configuration.SwaggerConfiguration;
import fr.gouv.vitamui.ui.commons.security.SecurityConfig; import fr.gouv.vitamui.ui.commons.security.SecurityConfig;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
@Configuration @Configuration
@Import(value = { SecurityConfig.class, SwaggerConfiguration.class, RestExceptionHandler.class }) @Import(value = { SecurityConfig.class, SwaggerConfiguration.class, RestExceptionHandler.class })
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment