Revision 53680
Added by Alessia Bardi almost 6 years ago
modules/dnet-openaire-exporter/branches/beta/pom.xml | ||
---|---|---|
1 |
<?xml version="1.0" encoding="UTF-8"?> |
|
2 |
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
|
3 |
<modelVersion>4.0.0</modelVersion> |
|
4 |
<groupId>eu.dnetlib</groupId> |
|
5 |
<artifactId>dnet-openaire-exporter</artifactId> |
|
6 |
<version>1.0.11-BETA-SNAPSHOT</version> |
|
7 |
<scm> |
|
8 |
<developerConnection>scm:svn:https://svn.driver.research-infrastructures.eu/driver/dnet45/modules/dnet-openaire-exporter/branches/beta</developerConnection> |
|
9 |
</scm> |
|
10 |
<ciManagement> |
|
11 |
<system>jenkins</system> |
|
12 |
<url>https://jenkins-dnet.d4science.org/view/DNet45/job/DSL45_dnet-openaire-exporter-BETA/</url> |
|
13 |
</ciManagement> |
|
14 |
<distributionManagement> |
|
15 |
<repository> |
|
16 |
<id>dnet45-releases</id> |
|
17 |
<name>D-Net 45 Releases</name> |
|
18 |
<url>http://maven.research-infrastructures.eu/nexus/content/repositories/dnet45-releases</url> |
|
19 |
<layout>default</layout> |
|
20 |
</repository> |
|
21 |
</distributionManagement> |
|
22 |
|
|
23 |
<!-- Inherit defaults from Spring Boot --> |
|
24 |
<parent> |
|
25 |
<groupId>org.springframework.boot</groupId> |
|
26 |
<artifactId>spring-boot-starter-parent</artifactId> |
|
27 |
<version>1.5.2.RELEASE</version> |
|
28 |
</parent> |
|
29 |
|
|
30 |
<repositories> |
|
31 |
<repository> |
|
32 |
<id>dnet-deps</id> |
|
33 |
<name>dnet-dependencies</name> |
|
34 |
<url>http://maven.research-infrastructures.eu/nexus/content/repositories/dnet-deps</url> |
|
35 |
<layout>default</layout> |
|
36 |
</repository> |
|
37 |
<repository> |
|
38 |
<id>dnet45-releases</id> |
|
39 |
<name>D-Net 45 Releases</name> |
|
40 |
<url>http://maven.research-infrastructures.eu/nexus/content/repositories/dnet45-releases</url> |
|
41 |
<layout>default</layout> |
|
42 |
<snapshots> |
|
43 |
<enabled>true</enabled> |
|
44 |
</snapshots> |
|
45 |
</repository> |
|
46 |
<repository> |
|
47 |
<id>dnet45-snapshots</id> |
|
48 |
<name>D-Net 45 Snapshots</name> |
|
49 |
<url>http://maven.research-infrastructures.eu/nexus/content/repositories/dnet45-snapshots</url> |
|
50 |
<layout>default</layout> |
|
51 |
<snapshots> |
|
52 |
<enabled>true</enabled> |
|
53 |
</snapshots> |
|
54 |
</repository> |
|
55 |
</repositories> |
|
56 |
<profiles> |
|
57 |
<profile> |
|
58 |
<id>java8-doclint-disabled</id> |
|
59 |
<activation> |
|
60 |
<jdk>[1.8,)</jdk> |
|
61 |
</activation> |
|
62 |
<properties> |
|
63 |
<javadoc.opts>-Xdoclint:none</javadoc.opts> |
|
64 |
</properties> |
|
65 |
</profile> |
|
66 |
</profiles> |
|
67 |
|
|
68 |
<!-- Add typical dependencies for a web application --> |
|
69 |
<dependencies> |
|
70 |
|
|
71 |
<dependency> |
|
72 |
<groupId>eu.dnetlib</groupId> |
|
73 |
<artifactId>cnr-rmi-api</artifactId> |
|
74 |
<version>[2.0.0,3.0.0)</version> |
|
75 |
</dependency> |
|
76 |
<dependency> |
|
77 |
<groupId>org.apache.cxf</groupId> |
|
78 |
<artifactId>cxf-rt-transports-http</artifactId> |
|
79 |
<version>3.1.5</version> |
|
80 |
</dependency> |
|
81 |
<dependency> |
|
82 |
<groupId>eu.dnetlib</groupId> |
|
83 |
<artifactId>cnr-service-common</artifactId> |
|
84 |
<version>[2.0.0,3.0.0)</version> |
|
85 |
</dependency> |
|
86 |
<dependency> |
|
87 |
<groupId>eu.dnetlib</groupId> |
|
88 |
<artifactId>dnet-openaireplus-mapping-utils</artifactId> |
|
89 |
<version>[6.0.0,7.0.0)</version> |
|
90 |
<exclusions> |
|
91 |
<exclusion> |
|
92 |
<groupId>com.sun.jersey</groupId> |
|
93 |
<artifactId>jersey-client</artifactId> |
|
94 |
</exclusion> |
|
95 |
<exclusion> |
|
96 |
<groupId>eu.dnetlib</groupId> |
|
97 |
<artifactId>dnet-hadoop-commons</artifactId> |
|
98 |
</exclusion> |
|
99 |
<exclusion> |
|
100 |
<groupId>eu.dnetlib</groupId> |
|
101 |
<artifactId>dnet-index-solr-common</artifactId> |
|
102 |
</exclusion> |
|
103 |
<exclusion> |
|
104 |
<groupId>org.apache.solr</groupId> |
|
105 |
<artifactId>solr-solrj</artifactId> |
|
106 |
</exclusion> |
|
107 |
</exclusions> |
|
108 |
</dependency> |
|
109 |
|
|
110 |
<dependency> |
|
111 |
<groupId>eu.dnetlib</groupId> |
|
112 |
<artifactId>dnet-objectstore-rmi</artifactId> |
|
113 |
<version>[2.0.0,3.0.0)</version> |
|
114 |
</dependency> |
|
115 |
|
|
116 |
<dependency> |
|
117 |
<groupId>org.apache.solr</groupId> |
|
118 |
<artifactId>solr-solrj</artifactId> |
|
119 |
<version>${apache.solr.version}</version> |
|
120 |
</dependency> |
|
121 |
|
|
122 |
<dependency> |
|
123 |
<groupId>org.springframework.boot</groupId> |
|
124 |
<artifactId>spring-boot-starter-web</artifactId> |
|
125 |
</dependency> |
|
126 |
|
|
127 |
<dependency> |
|
128 |
<groupId>org.springframework.boot</groupId> |
|
129 |
<artifactId>spring-boot-starter-jdbc</artifactId> |
|
130 |
</dependency> |
|
131 |
<dependency> |
|
132 |
<groupId>org.springframework.boot</groupId> |
|
133 |
<artifactId>spring-boot-starter-data-jpa</artifactId> |
|
134 |
</dependency> |
|
135 |
<dependency> |
|
136 |
<groupId>org.postgresql</groupId> |
|
137 |
<artifactId>postgresql</artifactId> |
|
138 |
<version>42.0.0</version> |
|
139 |
</dependency> |
|
140 |
<dependency> |
|
141 |
<groupId>org.apache.commons</groupId> |
|
142 |
<artifactId>commons-dbcp2</artifactId> |
|
143 |
<version>2.1</version> |
|
144 |
</dependency> |
|
145 |
<!-- TODO: migrate to stringtemplate4 --> |
|
146 |
<!--<dependency>--> |
|
147 |
<!--<groupId>org.antlr</groupId>--> |
|
148 |
<!--<artifactId>stringtemplate</artifactId>--> |
|
149 |
<!--<version>4.0.2</version>--> |
|
150 |
<!--</dependency>--> |
|
151 |
<dependency> |
|
152 |
<groupId>org.antlr</groupId> |
|
153 |
<artifactId>stringtemplate</artifactId> |
|
154 |
<version>3.2.1</version> |
|
155 |
</dependency> |
|
156 |
<dependency> |
|
157 |
<groupId>org.apache.commons</groupId> |
|
158 |
<artifactId>commons-lang3</artifactId> |
|
159 |
<version>3.5</version> |
|
160 |
</dependency> |
|
161 |
<dependency> |
|
162 |
<groupId>commons-io</groupId> |
|
163 |
<artifactId>commons-io</artifactId> |
|
164 |
<version>2.5</version> |
|
165 |
</dependency> |
|
166 |
|
|
167 |
<dependency> |
|
168 |
<groupId>com.google.guava</groupId> |
|
169 |
<artifactId>guava</artifactId> |
|
170 |
<version>${google.guava.version}</version> |
|
171 |
</dependency> |
|
172 |
<dependency> |
|
173 |
<groupId>net.sf.supercsv</groupId> |
|
174 |
<artifactId>super-csv</artifactId> |
|
175 |
<version>2.4.0</version> |
|
176 |
</dependency> |
|
177 |
<dependency> |
|
178 |
<groupId>com.google.code.gson</groupId> |
|
179 |
<artifactId>gson</artifactId> |
|
180 |
<version>${google.gson.version}</version> |
|
181 |
</dependency> |
|
182 |
|
|
183 |
|
|
184 |
<dependency> |
|
185 |
<groupId>com.fasterxml.jackson.datatype</groupId> |
|
186 |
<artifactId>jackson-datatype-joda</artifactId> |
|
187 |
<version>2.6.6</version> |
|
188 |
</dependency> |
|
189 |
<dependency> |
|
190 |
<groupId>joda-time</groupId> |
|
191 |
<artifactId>joda-time</artifactId> |
|
192 |
<version>2.8.2</version> |
|
193 |
</dependency> |
|
194 |
|
|
195 |
<dependency> |
|
196 |
<groupId>org.mongodb</groupId> |
|
197 |
<artifactId>mongo-java-driver</artifactId> |
|
198 |
<version>${mongodb.driver.version}</version> |
|
199 |
</dependency> |
|
200 |
|
|
201 |
<dependency> |
|
202 |
<groupId>io.springfox</groupId> |
|
203 |
<artifactId>springfox-swagger2</artifactId> |
|
204 |
<version>${springfox-version}</version> |
|
205 |
</dependency> |
|
206 |
<dependency> |
|
207 |
<groupId>io.springfox</groupId> |
|
208 |
<artifactId>springfox-swagger-ui</artifactId> |
|
209 |
<version>${springfox-version}</version> |
|
210 |
</dependency> |
|
211 |
|
|
212 |
<!-- for /metrics and /health controllers --> |
|
213 |
<dependency> |
|
214 |
<groupId>io.prometheus</groupId> |
|
215 |
<artifactId>simpleclient_spring_boot</artifactId> |
|
216 |
<version>${prometheus.version}</version> |
|
217 |
<exclusions> |
|
218 |
<exclusion> |
|
219 |
<groupId>org.springframework</groupId> |
|
220 |
<artifactId>spring-web</artifactId> |
|
221 |
</exclusion> |
|
222 |
</exclusions> |
|
223 |
</dependency> |
|
224 |
<dependency> |
|
225 |
<groupId>io.prometheus</groupId> |
|
226 |
<artifactId>simpleclient_hotspot</artifactId> |
|
227 |
<version>${prometheus.version}</version> |
|
228 |
</dependency> |
|
229 |
<dependency> |
|
230 |
<groupId>io.prometheus</groupId> |
|
231 |
<artifactId>simpleclient_servlet</artifactId> |
|
232 |
<version>${prometheus.version}</version> |
|
233 |
</dependency> |
|
234 |
|
|
235 |
<dependency> |
|
236 |
<groupId>net.bull.javamelody</groupId> |
|
237 |
<artifactId>javamelody-spring-boot-starter</artifactId> |
|
238 |
<version>1.71.0</version> |
|
239 |
</dependency> |
|
240 |
|
|
241 |
<dependency> |
|
242 |
<groupId>org.springframework.boot</groupId> |
|
243 |
<artifactId>spring-boot-starter-test</artifactId> |
|
244 |
<scope>test</scope> |
|
245 |
</dependency> |
|
246 |
|
|
247 |
</dependencies> |
|
248 |
|
|
249 |
<build> |
|
250 |
<plugins> |
|
251 |
<plugin> |
|
252 |
<groupId>org.springframework.boot</groupId> |
|
253 |
<artifactId>spring-boot-maven-plugin</artifactId> |
|
254 |
<configuration> |
|
255 |
<executable>true</executable> |
|
256 |
</configuration> |
|
257 |
</plugin> |
|
258 |
</plugins> |
|
259 |
</build> |
|
260 |
|
|
261 |
<properties> |
|
262 |
<java.version>1.8</java.version> |
|
263 |
<apache.solr.version>7.1.0</apache.solr.version> |
|
264 |
<google.guava.version>23.3-jre</google.guava.version> |
|
265 |
<google.gson.version>2.8.0</google.gson.version> |
|
266 |
<mongodb.driver.version>3.4.2</mongodb.driver.version> |
|
267 |
<springfox-version>2.7.0</springfox-version> |
|
268 |
<prometheus.version>0.0.25</prometheus.version> |
|
269 |
<maven.javadoc.failOnError>false</maven.javadoc.failOnError> |
|
270 |
</properties> |
|
271 |
</project> |
modules/dnet-openaire-exporter/branches/beta/dnet-openaire-exporter.iml | ||
---|---|---|
1 |
<?xml version="1.0" encoding="UTF-8"?> |
|
2 |
<module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4"> |
|
3 |
<component name="FacetManager"> |
|
4 |
<facet type="Spring" name="Spring"> |
|
5 |
<configuration /> |
|
6 |
</facet> |
|
7 |
</component> |
|
8 |
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8"> |
|
9 |
<output url="file://$MODULE_DIR$/target/classes" /> |
|
10 |
<output-test url="file://$MODULE_DIR$/target/test-classes" /> |
|
11 |
<content url="file://$MODULE_DIR$"> |
|
12 |
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" /> |
|
13 |
<sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" /> |
|
14 |
<sourceFolder url="file://$MODULE_DIR$/src/test/resources" type="java-test-resource" /> |
|
15 |
<sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" /> |
|
16 |
<excludeFolder url="file://$MODULE_DIR$/target" /> |
|
17 |
</content> |
|
18 |
<orderEntry type="inheritedJdk" /> |
|
19 |
<orderEntry type="sourceFolder" forTests="false" /> |
|
20 |
<orderEntry type="library" name="Maven: eu.dnetlib:dnet-pace-core:2.5.1" level="project" /> |
|
21 |
<orderEntry type="library" name="Maven: eu.dnetlib:cnr-rmi-api:2.6.2-SNAPSHOT" level="project" /> |
|
22 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-core:3.1.5" level="project" /> |
|
23 |
<orderEntry type="library" name="Maven: org.apache.ws.xmlschema:xmlschema-core:2.2.1" level="project" /> |
|
24 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-frontend-jaxws:3.1.5" level="project" /> |
|
25 |
<orderEntry type="library" name="Maven: xml-resolver:xml-resolver:1.2" level="project" /> |
|
26 |
<orderEntry type="library" name="Maven: org.ow2.asm:asm:5.0.4" level="project" /> |
|
27 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-bindings-soap:3.1.5" level="project" /> |
|
28 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-wsdl:3.1.5" level="project" /> |
|
29 |
<orderEntry type="library" name="Maven: wsdl4j:wsdl4j:1.6.3" level="project" /> |
|
30 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-databinding-jaxb:3.1.5" level="project" /> |
|
31 |
<orderEntry type="library" name="Maven: com.sun.xml.bind:jaxb-impl:2.2.11" level="project" /> |
|
32 |
<orderEntry type="library" name="Maven: com.sun.xml.bind:jaxb-core:2.2.11" level="project" /> |
|
33 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-bindings-xml:3.1.5" level="project" /> |
|
34 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-frontend-simple:3.1.5" level="project" /> |
|
35 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-ws-addr:3.1.5" level="project" /> |
|
36 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-ws-policy:3.1.5" level="project" /> |
|
37 |
<orderEntry type="library" name="Maven: org.apache.neethi:neethi:3.0.3" level="project" /> |
|
38 |
<orderEntry type="library" name="Maven: log4j:log4j:1.2.17" level="project" /> |
|
39 |
<orderEntry type="library" name="Maven: org.apache.cxf:cxf-rt-transports-http:3.1.5" level="project" /> |
|
40 |
<orderEntry type="module" module-name="cnr-service-common (1)" /> |
|
41 |
<orderEntry type="library" name="Maven: org.quartz-scheduler:quartz:2.2.2" level="project" /> |
|
42 |
<orderEntry type="library" name="Maven: c3p0:c3p0:0.9.1.1" level="project" /> |
|
43 |
<orderEntry type="library" name="Maven: org.springframework:spring-tx:4.3.7.RELEASE" level="project" /> |
|
44 |
<orderEntry type="library" name="Maven: org.springframework:spring-beans:4.3.7.RELEASE" level="project" /> |
|
45 |
<orderEntry type="library" name="Maven: eu.dnetlib:cnr-misc-utils:1.0.5-SNAPSHOT" level="project" /> |
|
46 |
<orderEntry type="library" name="Maven: commons-lang:commons-lang:2.6" level="project" /> |
|
47 |
<orderEntry type="library" name="Maven: jaxen:jaxen:1.1.6" level="project" /> |
|
48 |
<orderEntry type="library" name="Maven: saxonica:saxon:9.1.0.8" level="project" /> |
|
49 |
<orderEntry type="library" name="Maven: saxonica:saxon-dom:9.1.0.8" level="project" /> |
|
50 |
<orderEntry type="library" name="Maven: jgrapht:jgrapht:0.7.2" level="project" /> |
|
51 |
<orderEntry type="library" name="Maven: net.sf.ehcache:ehcache:2.10.3" level="project" /> |
|
52 |
<orderEntry type="library" name="Maven: eu.dnetlib:cnr-service-utils:1.0.3-SNAPSHOT" level="project" /> |
|
53 |
<orderEntry type="library" name="Maven: apache:oro:2.0.8" level="project" /> |
|
54 |
<orderEntry type="library" name="Maven: org.springframework:spring-context:4.3.7.RELEASE" level="project" /> |
|
55 |
<orderEntry type="library" name="Maven: eu.dnetlib:cnr-spring-utils:1.0.2-SNAPSHOT" level="project" /> |
|
56 |
<orderEntry type="library" name="Maven: org.springframework:spring-aop:4.3.7.RELEASE" level="project" /> |
|
57 |
<orderEntry type="library" name="Maven: jparsec:jparsec:2.0" level="project" /> |
|
58 |
<orderEntry type="library" name="Maven: runcc:runcc:0.7" level="project" /> |
|
59 |
<orderEntry type="module" module-name="dnet-openaireplus-mapping-utils" /> |
|
60 |
<orderEntry type="library" name="Maven: commons-codec:commons-codec:1.10" level="project" /> |
|
61 |
<orderEntry type="library" name="Maven: dom4j:dom4j:1.6.1" level="project" /> |
|
62 |
<orderEntry type="library" name="Maven: eu.dnetlib:dnet-openaire-data-protos:3.8.10" level="project" /> |
|
63 |
<orderEntry type="library" name="Maven: com.google.protobuf:protobuf-java:2.4.1" level="project" /> |
|
64 |
<orderEntry type="module" module-name="dnet-pace-core" /> |
|
65 |
<orderEntry type="library" name="Maven: edu.cmu:secondstring:1.0.0" level="project" /> |
|
66 |
<orderEntry type="library" name="Maven: commons-collections:commons-collections:3.2.2" level="project" /> |
|
67 |
<orderEntry type="library" name="Maven: com.googlecode.protobuf-java-format:protobuf-java-format:1.2" level="project" /> |
|
68 |
<orderEntry type="module" module-name="dnet-objectstore-rmi" /> |
|
69 |
<orderEntry type="library" name="Maven: org.apache.solr:solr-solrj:7.1.0" level="project" /> |
|
70 |
<orderEntry type="library" name="Maven: org.apache.commons:commons-math3:3.6.1" level="project" /> |
|
71 |
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpclient:4.5.3" level="project" /> |
|
72 |
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpcore:4.4.6" level="project" /> |
|
73 |
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpmime:4.5.3" level="project" /> |
|
74 |
<orderEntry type="library" name="Maven: org.apache.zookeeper:zookeeper:3.4.10" level="project" /> |
|
75 |
<orderEntry type="library" name="Maven: org.codehaus.woodstox:stax2-api:3.1.4" level="project" /> |
|
76 |
<orderEntry type="library" name="Maven: org.codehaus.woodstox:woodstox-core-asl:4.4.1" level="project" /> |
|
77 |
<orderEntry type="library" name="Maven: org.noggit:noggit:0.8" level="project" /> |
|
78 |
<orderEntry type="library" name="Maven: org.slf4j:jcl-over-slf4j:1.7.24" level="project" /> |
|
79 |
<orderEntry type="library" name="Maven: org.slf4j:slf4j-api:1.7.24" level="project" /> |
|
80 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-web:1.5.2.RELEASE" level="project" /> |
|
81 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter:1.5.2.RELEASE" level="project" /> |
|
82 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot:1.5.2.RELEASE" level="project" /> |
|
83 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-autoconfigure:1.5.2.RELEASE" level="project" /> |
|
84 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-logging:1.5.2.RELEASE" level="project" /> |
|
85 |
<orderEntry type="library" name="Maven: ch.qos.logback:logback-classic:1.1.11" level="project" /> |
|
86 |
<orderEntry type="library" name="Maven: ch.qos.logback:logback-core:1.1.11" level="project" /> |
|
87 |
<orderEntry type="library" name="Maven: org.slf4j:jul-to-slf4j:1.7.24" level="project" /> |
|
88 |
<orderEntry type="library" name="Maven: org.slf4j:log4j-over-slf4j:1.7.24" level="project" /> |
|
89 |
<orderEntry type="library" scope="RUNTIME" name="Maven: org.yaml:snakeyaml:1.17" level="project" /> |
|
90 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-tomcat:1.5.2.RELEASE" level="project" /> |
|
91 |
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-core:8.5.11" level="project" /> |
|
92 |
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-el:8.5.11" level="project" /> |
|
93 |
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-websocket:8.5.11" level="project" /> |
|
94 |
<orderEntry type="library" name="Maven: org.hibernate:hibernate-validator:5.3.4.Final" level="project" /> |
|
95 |
<orderEntry type="library" name="Maven: javax.validation:validation-api:1.1.0.Final" level="project" /> |
|
96 |
<orderEntry type="library" name="Maven: org.jboss.logging:jboss-logging:3.3.0.Final" level="project" /> |
|
97 |
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-databind:2.8.7" level="project" /> |
|
98 |
<orderEntry type="library" name="Maven: org.springframework:spring-web:4.3.7.RELEASE" level="project" /> |
|
99 |
<orderEntry type="library" name="Maven: org.springframework:spring-webmvc:4.3.7.RELEASE" level="project" /> |
|
100 |
<orderEntry type="library" name="Maven: org.springframework:spring-expression:4.3.7.RELEASE" level="project" /> |
|
101 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-jdbc:1.5.2.RELEASE" level="project" /> |
|
102 |
<orderEntry type="library" name="Maven: org.apache.tomcat:tomcat-jdbc:8.5.11" level="project" /> |
|
103 |
<orderEntry type="library" name="Maven: org.apache.tomcat:tomcat-juli:8.5.11" level="project" /> |
|
104 |
<orderEntry type="library" name="Maven: org.springframework:spring-jdbc:4.3.7.RELEASE" level="project" /> |
|
105 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-data-jpa:1.5.2.RELEASE" level="project" /> |
|
106 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-aop:1.5.2.RELEASE" level="project" /> |
|
107 |
<orderEntry type="library" name="Maven: org.aspectj:aspectjweaver:1.8.9" level="project" /> |
|
108 |
<orderEntry type="library" name="Maven: org.hibernate:hibernate-core:5.0.12.Final" level="project" /> |
|
109 |
<orderEntry type="library" name="Maven: org.hibernate.javax.persistence:hibernate-jpa-2.1-api:1.0.0.Final" level="project" /> |
|
110 |
<orderEntry type="library" name="Maven: org.javassist:javassist:3.21.0-GA" level="project" /> |
|
111 |
<orderEntry type="library" name="Maven: org.jboss:jandex:2.0.0.Final" level="project" /> |
|
112 |
<orderEntry type="library" name="Maven: org.hibernate.common:hibernate-commons-annotations:5.0.1.Final" level="project" /> |
|
113 |
<orderEntry type="library" name="Maven: org.hibernate:hibernate-entitymanager:5.0.12.Final" level="project" /> |
|
114 |
<orderEntry type="library" name="Maven: javax.transaction:javax.transaction-api:1.2" level="project" /> |
|
115 |
<orderEntry type="library" name="Maven: org.springframework.data:spring-data-jpa:1.11.1.RELEASE" level="project" /> |
|
116 |
<orderEntry type="library" name="Maven: org.springframework.data:spring-data-commons:1.13.1.RELEASE" level="project" /> |
|
117 |
<orderEntry type="library" name="Maven: org.springframework:spring-orm:4.3.7.RELEASE" level="project" /> |
|
118 |
<orderEntry type="library" name="Maven: org.springframework:spring-aspects:4.3.7.RELEASE" level="project" /> |
|
119 |
<orderEntry type="library" name="Maven: org.postgresql:postgresql:42.0.0" level="project" /> |
|
120 |
<orderEntry type="library" name="Maven: org.apache.commons:commons-dbcp2:2.1" level="project" /> |
|
121 |
<orderEntry type="library" name="Maven: org.apache.commons:commons-pool2:2.4.2" level="project" /> |
|
122 |
<orderEntry type="library" name="Maven: commons-logging:commons-logging:1.2" level="project" /> |
|
123 |
<orderEntry type="library" name="Maven: org.antlr:stringtemplate:3.2.1" level="project" /> |
|
124 |
<orderEntry type="library" name="Maven: antlr:antlr:2.7.7" level="project" /> |
|
125 |
<orderEntry type="library" name="Maven: org.apache.commons:commons-lang3:3.5" level="project" /> |
|
126 |
<orderEntry type="library" name="Maven: commons-io:commons-io:2.5" level="project" /> |
|
127 |
<orderEntry type="library" name="Maven: com.google.guava:guava:23.3-jre" level="project" /> |
|
128 |
<orderEntry type="library" name="Maven: com.google.code.findbugs:jsr305:1.3.9" level="project" /> |
|
129 |
<orderEntry type="library" name="Maven: com.google.errorprone:error_prone_annotations:2.0.18" level="project" /> |
|
130 |
<orderEntry type="library" name="Maven: com.google.j2objc:j2objc-annotations:1.1" level="project" /> |
|
131 |
<orderEntry type="library" name="Maven: org.codehaus.mojo:animal-sniffer-annotations:1.14" level="project" /> |
|
132 |
<orderEntry type="library" name="Maven: net.sf.supercsv:super-csv:2.4.0" level="project" /> |
|
133 |
<orderEntry type="library" name="Maven: com.google.code.gson:gson:2.8.0" level="project" /> |
|
134 |
<orderEntry type="library" name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-joda:2.6.6" level="project" /> |
|
135 |
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-annotations:2.8.0" level="project" /> |
|
136 |
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-core:2.8.7" level="project" /> |
|
137 |
<orderEntry type="library" name="Maven: joda-time:joda-time:2.8.2" level="project" /> |
|
138 |
<orderEntry type="library" name="Maven: org.mongodb:mongo-java-driver:3.4.2" level="project" /> |
|
139 |
<orderEntry type="library" name="Maven: io.springfox:springfox-swagger2:2.7.0" level="project" /> |
|
140 |
<orderEntry type="library" name="Maven: io.swagger:swagger-annotations:1.5.13" level="project" /> |
|
141 |
<orderEntry type="library" name="Maven: io.swagger:swagger-models:1.5.13" level="project" /> |
|
142 |
<orderEntry type="library" name="Maven: io.springfox:springfox-spi:2.7.0" level="project" /> |
|
143 |
<orderEntry type="library" name="Maven: io.springfox:springfox-core:2.7.0" level="project" /> |
|
144 |
<orderEntry type="library" name="Maven: net.bytebuddy:byte-buddy:1.6.14" level="project" /> |
|
145 |
<orderEntry type="library" name="Maven: io.springfox:springfox-schema:2.7.0" level="project" /> |
|
146 |
<orderEntry type="library" name="Maven: io.springfox:springfox-swagger-common:2.7.0" level="project" /> |
|
147 |
<orderEntry type="library" name="Maven: io.springfox:springfox-spring-web:2.7.0" level="project" /> |
|
148 |
<orderEntry type="library" name="Maven: org.reflections:reflections:0.9.11" level="project" /> |
|
149 |
<orderEntry type="library" name="Maven: com.fasterxml:classmate:1.3.3" level="project" /> |
|
150 |
<orderEntry type="library" name="Maven: org.springframework.plugin:spring-plugin-core:1.2.0.RELEASE" level="project" /> |
|
151 |
<orderEntry type="library" name="Maven: org.springframework.plugin:spring-plugin-metadata:1.2.0.RELEASE" level="project" /> |
|
152 |
<orderEntry type="library" name="Maven: org.mapstruct:mapstruct:1.1.0.Final" level="project" /> |
|
153 |
<orderEntry type="library" name="Maven: io.springfox:springfox-swagger-ui:2.7.0" level="project" /> |
|
154 |
<orderEntry type="library" name="Maven: io.prometheus:simpleclient_spring_boot:0.0.25" level="project" /> |
|
155 |
<orderEntry type="library" name="Maven: io.prometheus:simpleclient:0.0.25" level="project" /> |
|
156 |
<orderEntry type="library" name="Maven: io.prometheus:simpleclient_common:0.0.25" level="project" /> |
|
157 |
<orderEntry type="library" name="Maven: io.prometheus:simpleclient_spring_web:0.0.25" level="project" /> |
|
158 |
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-actuator:1.5.2.RELEASE" level="project" /> |
|
159 |
<orderEntry type="library" name="Maven: io.prometheus:simpleclient_hotspot:0.0.25" level="project" /> |
|
160 |
<orderEntry type="library" name="Maven: io.prometheus:simpleclient_servlet:0.0.25" level="project" /> |
|
161 |
<orderEntry type="library" scope="TEST" name="Maven: org.springframework.boot:spring-boot-starter-test:1.5.2.RELEASE" level="project" /> |
|
162 |
<orderEntry type="library" scope="TEST" name="Maven: org.springframework.boot:spring-boot-test:1.5.2.RELEASE" level="project" /> |
|
163 |
<orderEntry type="library" scope="TEST" name="Maven: org.springframework.boot:spring-boot-test-autoconfigure:1.5.2.RELEASE" level="project" /> |
|
164 |
<orderEntry type="library" scope="TEST" name="Maven: com.jayway.jsonpath:json-path:2.2.0" level="project" /> |
|
165 |
<orderEntry type="library" scope="TEST" name="Maven: net.minidev:json-smart:2.2.1" level="project" /> |
|
166 |
<orderEntry type="library" scope="TEST" name="Maven: net.minidev:accessors-smart:1.1" level="project" /> |
|
167 |
<orderEntry type="library" scope="TEST" name="Maven: junit:junit:4.12" level="project" /> |
|
168 |
<orderEntry type="library" scope="TEST" name="Maven: org.assertj:assertj-core:2.6.0" level="project" /> |
|
169 |
<orderEntry type="library" scope="TEST" name="Maven: org.mockito:mockito-core:1.10.19" level="project" /> |
|
170 |
<orderEntry type="library" scope="TEST" name="Maven: org.objenesis:objenesis:2.1" level="project" /> |
|
171 |
<orderEntry type="library" scope="TEST" name="Maven: org.hamcrest:hamcrest-core:1.3" level="project" /> |
|
172 |
<orderEntry type="library" scope="TEST" name="Maven: org.hamcrest:hamcrest-library:1.3" level="project" /> |
|
173 |
<orderEntry type="library" scope="TEST" name="Maven: org.skyscreamer:jsonassert:1.4.0" level="project" /> |
|
174 |
<orderEntry type="library" scope="TEST" name="Maven: com.vaadin.external.google:android-json:0.0.20131108.vaadin1" level="project" /> |
|
175 |
<orderEntry type="library" name="Maven: org.springframework:spring-core:4.3.7.RELEASE" level="project" /> |
|
176 |
<orderEntry type="library" name="Maven: org.springframework:spring-test:4.3.7.RELEASE" level="project" /> |
|
177 |
</component> |
|
178 |
</module> |
modules/dnet-openaire-exporter/branches/beta/deploy.info | ||
---|---|---|
1 |
{"type_source": "SVN", "goal": "package -U source:jar", |
|
2 |
"url": "http://svn-public.driver.research-infrastructures.eu/driver/dnet45/modules/dnet-openaire-exporter/trunk/", "deploy_repository": "dnet45-snapshots", "version": "4", "mail": "sandro.labruzzo@isti.cnr.it,michele.artini@isti.cnr.it, claudio.atzori@isti.cnr.it, alessia.bardi@isti.cnr.it", |
|
3 |
"deploy_repository_url": "http://maven.research-infrastructures.eu/nexus/content/repositories/dnet45-snapshots", "name": "dnet-openaire-exporter"} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/DNetOpenaireExporterApplication.java | ||
---|---|---|
1 |
package eu.dnetlib; |
|
2 |
|
|
3 |
import java.io.IOException; |
|
4 |
import java.util.List; |
|
5 |
import java.util.Set; |
|
6 |
import java.util.stream.Collectors; |
|
7 |
|
|
8 |
import javax.servlet.http.HttpServletResponse; |
|
9 |
|
|
10 |
import org.apache.commons.logging.Log; |
|
11 |
import org.apache.commons.logging.LogFactory; |
|
12 |
import org.springframework.beans.factory.annotation.Autowired; |
|
13 |
import org.springframework.boot.SpringApplication; |
|
14 |
import org.springframework.boot.autoconfigure.EnableAutoConfiguration; |
|
15 |
import org.springframework.boot.autoconfigure.SpringBootApplication; |
|
16 |
import org.springframework.boot.autoconfigure.solr.SolrAutoConfiguration; |
|
17 |
import org.springframework.cache.annotation.EnableCaching; |
|
18 |
import org.springframework.context.annotation.EnableAspectJAutoProxy; |
|
19 |
import org.springframework.web.bind.annotation.RequestMapping; |
|
20 |
import org.springframework.web.bind.annotation.RequestMethod; |
|
21 |
import org.springframework.web.bind.annotation.RestController; |
|
22 |
import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping; |
|
23 |
|
|
24 |
@EnableCaching |
|
25 |
@RestController |
|
26 |
@SpringBootApplication |
|
27 |
@EnableAspectJAutoProxy |
|
28 |
@EnableAutoConfiguration(exclude = { SolrAutoConfiguration.class }) |
|
29 |
public class DNetOpenaireExporterApplication { |
|
30 |
|
|
31 |
private static final Log log = LogFactory.getLog(DNetOpenaireExporterApplication.class); |
|
32 |
|
|
33 |
@Autowired |
|
34 |
private List<RequestMappingHandlerMapping> handlerMappings; |
|
35 |
|
|
36 |
@RequestMapping(value = { "/", "/docs" }) |
|
37 |
public void index(final HttpServletResponse response) throws IOException { |
|
38 |
response.sendRedirect("swagger-ui.html"); |
|
39 |
} |
|
40 |
|
|
41 |
@RequestMapping(value = "/endpointdoc", method = RequestMethod.GET) |
|
42 |
public Set<String> show() { |
|
43 |
return handlerMappings.stream() |
|
44 |
.map(handler -> handler.getHandlerMethods().keySet()) |
|
45 |
.map(rmInfo -> rmInfo.toString()) |
|
46 |
.collect(Collectors.toSet()); |
|
47 |
} |
|
48 |
|
|
49 |
public static void main(String[] args) throws Exception { |
|
50 |
SpringApplication.run(DNetOpenaireExporterApplication.class, args); |
|
51 |
} |
|
52 |
|
|
53 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/swagger/configuration/SwaggerDocumentationConfig.java | ||
---|---|---|
1 |
package eu.dnetlib.swagger.configuration; |
|
2 |
|
|
3 |
import eu.dnetlib.OpenaireExporterConfig; |
|
4 |
import eu.dnetlib.OpenaireExporterConfig.Swagger; |
|
5 |
import eu.dnetlib.common.rmi.DNetRestDocumentation; |
|
6 |
import org.springframework.beans.factory.annotation.Autowired; |
|
7 |
import org.springframework.context.annotation.Bean; |
|
8 |
import org.springframework.context.annotation.Configuration; |
|
9 |
import springfox.documentation.builders.ApiInfoBuilder; |
|
10 |
import springfox.documentation.builders.RequestHandlerSelectors; |
|
11 |
import springfox.documentation.service.ApiInfo; |
|
12 |
import springfox.documentation.service.Contact; |
|
13 |
import springfox.documentation.spi.DocumentationType; |
|
14 |
import springfox.documentation.spring.web.plugins.Docket; |
|
15 |
import springfox.documentation.swagger2.annotations.EnableSwagger2; |
|
16 |
|
|
17 |
@Configuration |
|
18 |
@EnableSwagger2 |
|
19 |
public class SwaggerDocumentationConfig { |
|
20 |
|
|
21 |
@Autowired |
|
22 |
private OpenaireExporterConfig config; |
|
23 |
|
|
24 |
@Bean |
|
25 |
public Docket customImplementation() { |
|
26 |
return new Docket(DocumentationType.SWAGGER_2) |
|
27 |
.select() |
|
28 |
.apis(RequestHandlerSelectors.withClassAnnotation(DNetRestDocumentation.class)) |
|
29 |
.build() |
|
30 |
.directModelSubstitute(org.joda.time.LocalDate.class, java.sql.Date.class) |
|
31 |
.directModelSubstitute(org.joda.time.DateTime.class, java.util.Date.class) |
|
32 |
.apiInfo(apiInfo()); |
|
33 |
} |
|
34 |
|
|
35 |
private ApiInfo apiInfo() { |
|
36 |
final Swagger swag = config.getSwagger(); |
|
37 |
return new ApiInfoBuilder() |
|
38 |
.title(swag.getApiTitle()) |
|
39 |
.description(swag.getApiDescription()) |
|
40 |
.license(swag.getApiLicense()) |
|
41 |
.licenseUrl(swag.getApiLicenseUrl()) |
|
42 |
.termsOfServiceUrl("") |
|
43 |
.version("1.0.0") |
|
44 |
.contact(new Contact( |
|
45 |
swag.getApiContactName(), |
|
46 |
swag.getApiContactUrl(), |
|
47 |
swag.getApiContactEmail())) |
|
48 |
.build(); |
|
49 |
} |
|
50 |
|
|
51 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/swagger/configuration/RFC3339DateFormat.java | ||
---|---|---|
1 |
package eu.dnetlib.swagger.configuration; |
|
2 |
|
|
3 |
import java.text.FieldPosition; |
|
4 |
import java.util.Date; |
|
5 |
|
|
6 |
import com.fasterxml.jackson.databind.util.ISO8601DateFormat; |
|
7 |
import com.fasterxml.jackson.databind.util.ISO8601Utils; |
|
8 |
|
|
9 |
public class RFC3339DateFormat extends ISO8601DateFormat { |
|
10 |
|
|
11 |
// Same as ISO8601DateFormat but serializing milliseconds. |
|
12 |
@Override |
|
13 |
public StringBuffer format(Date date, StringBuffer toAppendTo, FieldPosition fieldPosition) { |
|
14 |
String value = ISO8601Utils.format(date, true); |
|
15 |
toAppendTo.append(value); |
|
16 |
return toAppendTo; |
|
17 |
} |
|
18 |
|
|
19 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/Utils.java | ||
---|---|---|
1 |
package eu.dnetlib; |
|
2 |
|
|
3 |
import java.util.Iterator; |
|
4 |
import java.util.Spliterator; |
|
5 |
import java.util.Spliterators; |
|
6 |
import java.util.stream.Stream; |
|
7 |
import java.util.stream.StreamSupport; |
|
8 |
|
|
9 |
/** |
|
10 |
* Created by claudio on 13/04/2017. |
|
11 |
*/ |
|
12 |
public class Utils { |
|
13 |
|
|
14 |
public static <T> Stream<T> stream(Iterator<T> iterator) { |
|
15 |
return StreamSupport.stream(Spliterators.spliteratorUnknownSize(iterator, Spliterator.ORDERED), false); |
|
16 |
} |
|
17 |
|
|
18 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/OpenaireExporterConfig.java | ||
---|---|---|
1 |
package eu.dnetlib; |
|
2 |
|
|
3 |
import org.springframework.beans.factory.annotation.Value; |
|
4 |
import org.springframework.boot.context.properties.ConfigurationProperties; |
|
5 |
import org.springframework.core.io.ClassPathResource; |
|
6 |
import org.springframework.core.io.Resource; |
|
7 |
import org.springframework.stereotype.Component; |
|
8 |
|
|
9 |
/** |
|
10 |
* Created by Alessia Bardi on 31/03/17. |
|
11 |
* |
|
12 |
* @author Alessia Bardi, Claudio Atzori |
|
13 |
*/ |
|
14 |
@Component |
|
15 |
@ConfigurationProperties(prefix = "openaire.exporter") |
|
16 |
public class OpenaireExporterConfig { |
|
17 |
|
|
18 |
// ISLOOKUP |
|
19 |
private ClassPathResource findSolrIndexUrl; |
|
20 |
private ClassPathResource findIndexDsInfo; |
|
21 |
private ClassPathResource findObjectStore; |
|
22 |
private ClassPathResource findFunderContexts; |
|
23 |
private ClassPathResource findCommunityContexts; |
|
24 |
|
|
25 |
private String isLookupUrl; |
|
26 |
private String objectStoreServiceUrl; |
|
27 |
|
|
28 |
private int requestWorkers = 100; |
|
29 |
private int requestTimeout = 10; |
|
30 |
|
|
31 |
private Datasource datasource; |
|
32 |
private Project project; |
|
33 |
private Jdbc jdbc; |
|
34 |
private Swagger swagger; |
|
35 |
private Vocabularies vocabularies; |
|
36 |
|
|
37 |
public static class Datasource { |
|
38 |
// MONGODB |
|
39 |
private String mongoHost; |
|
40 |
private int mongoPort; |
|
41 |
private String mongoCollectionName; |
|
42 |
private String mongoDbName; |
|
43 |
private int mongoConnectionsPerHost; |
|
44 |
private int mongoQueryLimit; |
|
45 |
|
|
46 |
public String getMongoHost() { |
|
47 |
return mongoHost; |
|
48 |
} |
|
49 |
|
|
50 |
public void setMongoHost(final String mongoHost) { |
|
51 |
this.mongoHost = mongoHost; |
|
52 |
} |
|
53 |
|
|
54 |
public int getMongoPort() { |
|
55 |
return mongoPort; |
|
56 |
} |
|
57 |
|
|
58 |
public void setMongoPort(final int mongoPort) { |
|
59 |
this.mongoPort = mongoPort; |
|
60 |
} |
|
61 |
|
|
62 |
public String getMongoCollectionName() { |
|
63 |
return mongoCollectionName; |
|
64 |
} |
|
65 |
|
|
66 |
public void setMongoCollectionName(final String mongoCollectionName) { |
|
67 |
this.mongoCollectionName = mongoCollectionName; |
|
68 |
} |
|
69 |
|
|
70 |
public String getMongoDbName() { |
|
71 |
return mongoDbName; |
|
72 |
} |
|
73 |
|
|
74 |
public void setMongoDbName(final String mongoDbName) { |
|
75 |
this.mongoDbName = mongoDbName; |
|
76 |
} |
|
77 |
|
|
78 |
public int getMongoConnectionsPerHost() { |
|
79 |
return mongoConnectionsPerHost; |
|
80 |
} |
|
81 |
|
|
82 |
public void setMongoConnectionsPerHost(final int mongoConnectionsPerHost) { |
|
83 |
this.mongoConnectionsPerHost = mongoConnectionsPerHost; |
|
84 |
} |
|
85 |
|
|
86 |
public int getMongoQueryLimit() { |
|
87 |
return mongoQueryLimit; |
|
88 |
} |
|
89 |
|
|
90 |
public void setMongoQueryLimit(final int mongoQueryLimit) { |
|
91 |
this.mongoQueryLimit = mongoQueryLimit; |
|
92 |
} |
|
93 |
} |
|
94 |
|
|
95 |
public static class Project { |
|
96 |
|
|
97 |
private int flushSize; |
|
98 |
private String tsvFields; |
|
99 |
private Resource projectsFundingQueryTemplate; |
|
100 |
private Resource dspaceTemplate; |
|
101 |
private Resource dspaceHeadTemplate; |
|
102 |
private Resource dspaceTailTemplate; |
|
103 |
private Resource eprintsTemplate; |
|
104 |
|
|
105 |
public int getFlushSize() { |
|
106 |
return flushSize; |
|
107 |
} |
|
108 |
|
|
109 |
public void setFlushSize(final int flushSize) { |
|
110 |
this.flushSize = flushSize; |
|
111 |
} |
|
112 |
|
|
113 |
public String getTsvFields() { |
|
114 |
return tsvFields; |
|
115 |
} |
|
116 |
|
|
117 |
public void setTsvFields(final String tsvFields) { |
|
118 |
this.tsvFields = tsvFields; |
|
119 |
} |
|
120 |
|
|
121 |
public Resource getProjectsFundingQueryTemplate() { |
|
122 |
return projectsFundingQueryTemplate; |
|
123 |
} |
|
124 |
|
|
125 |
public void setProjectsFundingQueryTemplate(final Resource projectsFundingQueryTemplate) { |
|
126 |
this.projectsFundingQueryTemplate = projectsFundingQueryTemplate; |
|
127 |
} |
|
128 |
|
|
129 |
public Resource getDspaceTemplate() { |
|
130 |
return dspaceTemplate; |
|
131 |
} |
|
132 |
|
|
133 |
public void setDspaceTemplate(final Resource dspaceTemplate) { |
|
134 |
this.dspaceTemplate = dspaceTemplate; |
|
135 |
} |
|
136 |
|
|
137 |
public Resource getDspaceHeadTemplate() { |
|
138 |
return dspaceHeadTemplate; |
|
139 |
} |
|
140 |
|
|
141 |
public void setDspaceHeadTemplate(final Resource dspaceHeadTemplate) { |
|
142 |
this.dspaceHeadTemplate = dspaceHeadTemplate; |
|
143 |
} |
|
144 |
|
|
145 |
public Resource getDspaceTailTemplate() { |
|
146 |
return dspaceTailTemplate; |
|
147 |
} |
|
148 |
|
|
149 |
public void setDspaceTailTemplate(final Resource dspaceTailTemplate) { |
|
150 |
this.dspaceTailTemplate = dspaceTailTemplate; |
|
151 |
} |
|
152 |
|
|
153 |
public Resource getEprintsTemplate() { |
|
154 |
return eprintsTemplate; |
|
155 |
} |
|
156 |
|
|
157 |
public void setEprintsTemplate(final Resource eprintsTemplate) { |
|
158 |
this.eprintsTemplate = eprintsTemplate; |
|
159 |
} |
|
160 |
} |
|
161 |
|
|
162 |
public static class Jdbc { |
|
163 |
|
|
164 |
// JDBC |
|
165 |
@Value("${spring.datasource.driverClassName}") |
|
166 |
private String driverClassName; |
|
167 |
|
|
168 |
private String url; |
|
169 |
private String user; |
|
170 |
private String pwd; |
|
171 |
private int minIdle; |
|
172 |
private int maxidle; |
|
173 |
private int maxRows; |
|
174 |
|
|
175 |
public String getDriverClassName() { |
|
176 |
return driverClassName; |
|
177 |
} |
|
178 |
|
|
179 |
public String getUrl() { |
|
180 |
return url; |
|
181 |
} |
|
182 |
|
|
183 |
public void setUrl(final String url) { |
|
184 |
this.url = url; |
|
185 |
} |
|
186 |
|
|
187 |
public String getUser() { |
|
188 |
return user; |
|
189 |
} |
|
190 |
|
|
191 |
public void setUser(final String user) { |
|
192 |
this.user = user; |
|
193 |
} |
|
194 |
|
|
195 |
public String getPwd() { |
|
196 |
return pwd; |
|
197 |
} |
|
198 |
|
|
199 |
public void setPwd(final String pwd) { |
|
200 |
this.pwd = pwd; |
|
201 |
} |
|
202 |
|
|
203 |
public int getMinIdle() { |
|
204 |
return minIdle; |
|
205 |
} |
|
206 |
|
|
207 |
public void setMinIdle(final int minIdle) { |
|
208 |
this.minIdle = minIdle; |
|
209 |
} |
|
210 |
|
|
211 |
public int getMaxidle() { |
|
212 |
return maxidle; |
|
213 |
} |
|
214 |
|
|
215 |
public void setMaxidle(final int maxidle) { |
|
216 |
this.maxidle = maxidle; |
|
217 |
} |
|
218 |
|
|
219 |
public int getMaxRows() { |
|
220 |
return maxRows; |
|
221 |
} |
|
222 |
|
|
223 |
public void setMaxRows(final int maxRows) { |
|
224 |
this.maxRows = maxRows; |
|
225 |
} |
|
226 |
} |
|
227 |
|
|
228 |
public static class Swagger { |
|
229 |
private String apiTitle; |
|
230 |
private String apiDescription; |
|
231 |
private String apiLicense; |
|
232 |
private String apiLicenseUrl; |
|
233 |
private String apiContactName; |
|
234 |
private String apiContactUrl; |
|
235 |
private String apiContactEmail; |
|
236 |
|
|
237 |
public String getApiTitle() { |
|
238 |
return apiTitle; |
|
239 |
} |
|
240 |
|
|
241 |
public void setApiTitle(final String apiTitle) { |
|
242 |
this.apiTitle = apiTitle; |
|
243 |
} |
|
244 |
|
|
245 |
public String getApiDescription() { |
|
246 |
return apiDescription; |
|
247 |
} |
|
248 |
|
|
249 |
public void setApiDescription(final String apiDescription) { |
|
250 |
this.apiDescription = apiDescription; |
|
251 |
} |
|
252 |
|
|
253 |
public String getApiLicense() { |
|
254 |
return apiLicense; |
|
255 |
} |
|
256 |
|
|
257 |
public void setApiLicense(final String apiLicense) { |
|
258 |
this.apiLicense = apiLicense; |
|
259 |
} |
|
260 |
|
|
261 |
public String getApiLicenseUrl() { |
|
262 |
return apiLicenseUrl; |
|
263 |
} |
|
264 |
|
|
265 |
public void setApiLicenseUrl(final String apiLicenseUrl) { |
|
266 |
this.apiLicenseUrl = apiLicenseUrl; |
|
267 |
} |
|
268 |
|
|
269 |
public String getApiContactName() { |
|
270 |
return apiContactName; |
|
271 |
} |
|
272 |
|
|
273 |
public void setApiContactName(final String apiContactName) { |
|
274 |
this.apiContactName = apiContactName; |
|
275 |
} |
|
276 |
|
|
277 |
public String getApiContactUrl() { |
|
278 |
return apiContactUrl; |
|
279 |
} |
|
280 |
|
|
281 |
public void setApiContactUrl(final String apiContactUrl) { |
|
282 |
this.apiContactUrl = apiContactUrl; |
|
283 |
} |
|
284 |
|
|
285 |
public String getApiContactEmail() { |
|
286 |
return apiContactEmail; |
|
287 |
} |
|
288 |
|
|
289 |
public void setApiContactEmail(final String apiContactEmail) { |
|
290 |
this.apiContactEmail = apiContactEmail; |
|
291 |
} |
|
292 |
} |
|
293 |
|
|
294 |
public static class Vocabularies { |
|
295 |
|
|
296 |
private String baseUrl; |
|
297 |
|
|
298 |
private String countriesEndpoint; |
|
299 |
|
|
300 |
private String datasourceTypologiesEndpoint; |
|
301 |
|
|
302 |
public String getCountriesEndpoint() { |
|
303 |
return countriesEndpoint; |
|
304 |
} |
|
305 |
|
|
306 |
public void setCountriesEndpoint(final String countriesEndpoint) { |
|
307 |
this.countriesEndpoint = countriesEndpoint; |
|
308 |
} |
|
309 |
|
|
310 |
public String getBaseUrl() { |
|
311 |
return baseUrl; |
|
312 |
} |
|
313 |
|
|
314 |
public void setBaseUrl(final String baseUrl) { |
|
315 |
this.baseUrl = baseUrl; |
|
316 |
} |
|
317 |
|
|
318 |
public String getDatasourceTypologiesEndpoint() { |
|
319 |
return datasourceTypologiesEndpoint; |
|
320 |
} |
|
321 |
|
|
322 |
public void setDatasourceTypologiesEndpoint(final String datasourceTypologiesEndpoint) { |
|
323 |
this.datasourceTypologiesEndpoint = datasourceTypologiesEndpoint; |
|
324 |
} |
|
325 |
} |
|
326 |
|
|
327 |
public ClassPathResource getFindSolrIndexUrl() { |
|
328 |
return findSolrIndexUrl; |
|
329 |
} |
|
330 |
|
|
331 |
public void setFindSolrIndexUrl(final ClassPathResource findSolrIndexUrl) { |
|
332 |
this.findSolrIndexUrl = findSolrIndexUrl; |
|
333 |
} |
|
334 |
|
|
335 |
public ClassPathResource getFindIndexDsInfo() { |
|
336 |
return findIndexDsInfo; |
|
337 |
} |
|
338 |
|
|
339 |
public ClassPathResource getFindObjectStore() { |
|
340 |
return findObjectStore; |
|
341 |
} |
|
342 |
|
|
343 |
public void setFindObjectStore(final ClassPathResource findObjectStore) { |
|
344 |
this.findObjectStore = findObjectStore; |
|
345 |
} |
|
346 |
|
|
347 |
public ClassPathResource getFindFunderContexts() { |
|
348 |
return findFunderContexts; |
|
349 |
} |
|
350 |
|
|
351 |
public void setFindFunderContexts(final ClassPathResource findFunderContexts) { |
|
352 |
this.findFunderContexts = findFunderContexts; |
|
353 |
} |
|
354 |
|
|
355 |
public ClassPathResource getFindCommunityContexts() { |
|
356 |
return findCommunityContexts; |
|
357 |
} |
|
358 |
|
|
359 |
public void setFindCommunityContexts(final ClassPathResource findCommunityContexts) { |
|
360 |
this.findCommunityContexts = findCommunityContexts; |
|
361 |
} |
|
362 |
|
|
363 |
public void setFindIndexDsInfo(final ClassPathResource findIndexDsInfo) { |
|
364 |
this.findIndexDsInfo = findIndexDsInfo; |
|
365 |
} |
|
366 |
|
|
367 |
public String getIsLookupUrl() { |
|
368 |
return isLookupUrl; |
|
369 |
} |
|
370 |
|
|
371 |
public void setIsLookupUrl(final String isLookupUrl) { |
|
372 |
this.isLookupUrl = isLookupUrl; |
|
373 |
} |
|
374 |
|
|
375 |
public String getObjectStoreServiceUrl() { |
|
376 |
return objectStoreServiceUrl; |
|
377 |
} |
|
378 |
|
|
379 |
public void setObjectStoreServiceUrl(final String objectStoreServiceUrl) { |
|
380 |
this.objectStoreServiceUrl = objectStoreServiceUrl; |
|
381 |
} |
|
382 |
|
|
383 |
public int getRequestWorkers() { |
|
384 |
return requestWorkers; |
|
385 |
} |
|
386 |
|
|
387 |
public void setRequestWorkers(final int requestWorkers) { |
|
388 |
this.requestWorkers = requestWorkers; |
|
389 |
} |
|
390 |
|
|
391 |
public int getRequestTimeout() { |
|
392 |
return requestTimeout; |
|
393 |
} |
|
394 |
|
|
395 |
public void setRequestTimeout(final int requestTimeout) { |
|
396 |
this.requestTimeout = requestTimeout; |
|
397 |
} |
|
398 |
|
|
399 |
public Datasource getDatasource() { |
|
400 |
return datasource; |
|
401 |
} |
|
402 |
|
|
403 |
public void setDatasource(final Datasource datasource) { |
|
404 |
this.datasource = datasource; |
|
405 |
} |
|
406 |
|
|
407 |
public Project getProject() { |
|
408 |
return project; |
|
409 |
} |
|
410 |
|
|
411 |
public void setProject(final Project project) { |
|
412 |
this.project = project; |
|
413 |
} |
|
414 |
|
|
415 |
public Jdbc getJdbc() { |
|
416 |
return jdbc; |
|
417 |
} |
|
418 |
|
|
419 |
public void setJdbc(final Jdbc jdbc) { |
|
420 |
this.jdbc = jdbc; |
|
421 |
} |
|
422 |
|
|
423 |
public Swagger getSwagger() { |
|
424 |
return swagger; |
|
425 |
} |
|
426 |
|
|
427 |
public void setSwagger(final Swagger swagger) { |
|
428 |
this.swagger = swagger; |
|
429 |
} |
|
430 |
|
|
431 |
public Vocabularies getVocabularies() { |
|
432 |
return vocabularies; |
|
433 |
} |
|
434 |
|
|
435 |
public void setVocabularies(final Vocabularies vocabularies) { |
|
436 |
this.vocabularies = vocabularies; |
|
437 |
} |
|
438 |
|
|
439 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/openaire/exporter/aop/DatasourceApiProfiler.java | ||
---|---|---|
1 |
package eu.dnetlib.openaire.exporter.aop; |
|
2 |
|
|
3 |
import io.prometheus.client.Gauge; |
|
4 |
import org.aspectj.lang.ProceedingJoinPoint; |
|
5 |
import org.aspectj.lang.annotation.Around; |
|
6 |
import org.aspectj.lang.annotation.Aspect; |
|
7 |
import org.springframework.stereotype.Component; |
|
8 |
|
|
9 |
/** |
|
10 |
* Created by claudio on 25/07/2017. |
|
11 |
*/ |
|
12 |
@Aspect |
|
13 |
@Component |
|
14 |
public class DatasourceApiProfiler { |
|
15 |
|
|
16 |
private static final Gauge datasourceByIdGauge = Gauge.build() |
|
17 |
.name("DSM_getDsById_requests_latency_seconds") |
|
18 |
.help("Request latency in seconds for invocations of the method eu.dnetlib.openaire.exporter.datasource.DatasourcesApiController.getDs()") |
|
19 |
.register(); |
|
20 |
|
|
21 |
@Around("execution(* eu.dnetlib.openaire.exporter.datasource.DatasourcesApiController.getDs(..))") |
|
22 |
public Object logTimeGetDsById(final ProceedingJoinPoint joinPoint) throws Throwable { |
|
23 |
final Gauge.Timer requestTimer = datasourceByIdGauge.startTimer(); |
|
24 |
try { |
|
25 |
return joinPoint.proceed(); |
|
26 |
} finally { |
|
27 |
requestTimer.setDuration(); |
|
28 |
} |
|
29 |
} |
|
30 |
|
|
31 |
private static final Gauge datasourceByName = Gauge.build() |
|
32 |
.name("DSM_searchDsByName_requests_latency_seconds") |
|
33 |
.help("Request latency in seconds for invocations of the method eu.dnetlib.openaire.exporter.datasource.DatasourcesApiController.searchByName()") |
|
34 |
.register(); |
|
35 |
|
|
36 |
@Around("execution(* eu.dnetlib.openaire.exporter.datasource.DatasourcesApiController.searchByName(..))") |
|
37 |
public Object logTimeSearchDsByName(final ProceedingJoinPoint joinPoint) throws Throwable { |
|
38 |
final Gauge.Timer requestTimer = datasourceByName.startTimer(); |
|
39 |
try { |
|
40 |
return joinPoint.proceed(); |
|
41 |
} finally { |
|
42 |
requestTimer.setDuration(); |
|
43 |
} |
|
44 |
} |
|
45 |
|
|
46 |
|
|
47 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/openaire/exporter/vocabularies/Country.java | ||
---|---|---|
1 |
package eu.dnetlib.openaire.exporter.vocabularies; |
|
2 |
|
|
3 |
/** |
|
4 |
* Created by claudio on 15/09/2017. |
|
5 |
*/ |
|
6 |
public class Country { |
|
7 |
|
|
8 |
private String code; |
|
9 |
|
|
10 |
private String name; |
|
11 |
|
|
12 |
public Country() { |
|
13 |
} |
|
14 |
|
|
15 |
public Country(final String code, final String name) { |
|
16 |
this.code = code; |
|
17 |
this.name = name; |
|
18 |
} |
|
19 |
|
|
20 |
public String getCode() { |
|
21 |
return code; |
|
22 |
} |
|
23 |
|
|
24 |
public void setCode(final String code) { |
|
25 |
this.code = code; |
|
26 |
} |
|
27 |
|
|
28 |
public String getName() { |
|
29 |
return name; |
|
30 |
} |
|
31 |
|
|
32 |
public void setName(final String name) { |
|
33 |
this.name = name; |
|
34 |
} |
|
35 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/openaire/exporter/vocabularies/Term.java | ||
---|---|---|
1 |
package eu.dnetlib.openaire.exporter.vocabularies; |
|
2 |
|
|
3 |
/** |
|
4 |
* Created by claudio on 15/09/2017. |
|
5 |
*/ |
|
6 |
public class Term { |
|
7 |
private String englishName; |
|
8 |
private String code; |
|
9 |
|
|
10 |
public Term() { |
|
11 |
} |
|
12 |
|
|
13 |
public String getEnglishName() { |
|
14 |
return englishName; |
|
15 |
} |
|
16 |
|
|
17 |
public void setEnglishName(final String englishName) { |
|
18 |
this.englishName = englishName; |
|
19 |
} |
|
20 |
|
|
21 |
public String getCode() { |
|
22 |
return code; |
|
23 |
} |
|
24 |
|
|
25 |
public void setCode(final String code) { |
|
26 |
this.code = code; |
|
27 |
} |
|
28 |
|
|
29 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/openaire/exporter/vocabularies/Vocabulary.java | ||
---|---|---|
1 |
package eu.dnetlib.openaire.exporter.vocabularies; |
|
2 |
|
|
3 |
import java.util.List; |
|
4 |
import java.util.Map; |
|
5 |
|
|
6 |
import com.google.common.collect.Maps; |
|
7 |
import org.apache.commons.logging.Log; |
|
8 |
import org.apache.commons.logging.LogFactory; |
|
9 |
|
|
10 |
/** |
|
11 |
* Created by claudio on 15/09/2017. |
|
12 |
*/ |
|
13 |
public class Vocabulary { |
|
14 |
|
|
15 |
private static final Log log = LogFactory.getLog(Vocabulary.class); |
|
16 |
|
|
17 |
private List<Term> terms; |
|
18 |
|
|
19 |
public Vocabulary() { |
|
20 |
} |
|
21 |
|
|
22 |
private static Map<String, Term> byCode = Maps.newConcurrentMap(); |
|
23 |
|
|
24 |
public String getEnglishName(final String code) { |
|
25 |
if (byCode.isEmpty()) { |
|
26 |
hashByCode(); |
|
27 |
} |
|
28 |
final Term term = byCode.get(code); |
|
29 |
return term != null ? term.getEnglishName() : null; |
|
30 |
} |
|
31 |
|
|
32 |
public boolean hasCode(final String code) { |
|
33 |
return getEnglishName(code) != null; |
|
34 |
} |
|
35 |
|
|
36 |
private void hashByCode() { |
|
37 |
log.info("hashing vocabulary by code ..."); |
|
38 |
getTerms().forEach(term -> byCode.put(term.getCode(), term)); |
|
39 |
log.info("hashing vocabulary by code ... done!"); |
|
40 |
} |
|
41 |
|
|
42 |
public List<Term> getTerms() { |
|
43 |
return terms; |
|
44 |
} |
|
45 |
|
|
46 |
public void setTerms(final List<Term> terms) { |
|
47 |
this.terms = terms; |
|
48 |
} |
|
49 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/openaire/exporter/AbstractExporterController.java | ||
---|---|---|
1 |
package eu.dnetlib.openaire.exporter; |
|
2 |
|
|
3 |
import org.apache.commons.lang3.StringUtils; |
|
4 |
import org.apache.commons.lang3.exception.ExceptionUtils; |
|
5 |
import org.apache.commons.logging.Log; |
|
6 |
import org.apache.commons.logging.LogFactory; |
|
7 |
import org.springframework.http.HttpStatus; |
|
8 |
import org.springframework.web.bind.annotation.ExceptionHandler; |
|
9 |
import org.springframework.web.bind.annotation.ResponseBody; |
|
10 |
import org.springframework.web.bind.annotation.ResponseStatus; |
|
11 |
|
|
12 |
/** |
|
13 |
* Created by claudio on 18/07/2017. |
|
14 |
*/ |
|
15 |
public abstract class AbstractExporterController { |
|
16 |
|
|
17 |
private static final Log log = LogFactory.getLog(AbstractExporterController.class); // NOPMD by marko on 11/24/08 5:02 PM |
|
18 |
|
|
19 |
@ResponseBody |
|
20 |
@ExceptionHandler({Exception.class, Throwable.class}) |
|
21 |
@ResponseStatus(value = HttpStatus.INTERNAL_SERVER_ERROR) |
|
22 |
public ErrorMessage handleSqlException(final Exception e) { |
|
23 |
log.debug(e.getMessage(), e); |
|
24 |
if (StringUtils.containsIgnoreCase(ExceptionUtils.getRootCauseMessage(e), "Broken pipe")) { |
|
25 |
return null; //socket is closed, cannot return any response |
|
26 |
} else { |
|
27 |
return new ErrorMessage(e); |
|
28 |
} |
|
29 |
} |
|
30 |
|
|
31 |
public class ErrorMessage { |
|
32 |
|
|
33 |
private final String message; |
|
34 |
private final String stacktrace; |
|
35 |
|
|
36 |
public ErrorMessage(final Exception e) { |
|
37 |
this(e.getMessage(), ExceptionUtils.getStackTrace(e)); |
|
38 |
} |
|
39 |
|
|
40 |
public ErrorMessage(final String message, final String stacktrace) { |
|
41 |
this.message = message; |
|
42 |
this.stacktrace = stacktrace; |
|
43 |
} |
|
44 |
|
|
45 |
public String getMessage() { |
|
46 |
return this.message; |
|
47 |
} |
|
48 |
|
|
49 |
public String getStacktrace() { |
|
50 |
return this.stacktrace; |
|
51 |
} |
|
52 |
} |
|
53 |
|
|
54 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/openaire/exporter/model/Header.java | ||
---|---|---|
1 |
package eu.dnetlib.openaire.exporter.model; |
|
2 |
|
|
3 |
import java.util.List; |
|
4 |
import java.util.Queue; |
|
5 |
import java.util.stream.Collectors; |
|
6 |
|
|
7 |
import com.fasterxml.jackson.annotation.JsonAutoDetect; |
|
8 |
import com.fasterxml.jackson.annotation.JsonIgnore; |
|
9 |
import com.google.gson.GsonBuilder; |
|
10 |
import io.swagger.annotations.ApiModel; |
|
11 |
|
|
12 |
/** |
|
13 |
* Created by claudio on 24/11/2016. |
|
14 |
*/ |
|
15 |
@ApiModel |
|
16 |
@JsonAutoDetect |
|
17 |
public class Header { |
|
18 |
|
|
19 |
private long total; |
|
20 |
private int page; |
|
21 |
private int size; |
|
22 |
private long time; |
|
23 |
private int statusCode; |
|
24 |
private List<String> errors; |
|
25 |
|
|
26 |
@JsonIgnore |
|
27 |
private Queue<Throwable> exceptions; |
|
28 |
|
|
29 |
public static Header newInsance() { |
|
30 |
return new Header(); |
|
31 |
} |
|
32 |
|
|
33 |
public Header() {} |
|
34 |
|
|
35 |
public long getTime() { |
|
36 |
return time; |
|
37 |
} |
|
38 |
|
|
39 |
public Header setTime(final long time) { |
|
40 |
this.time = time; |
|
41 |
return this; |
|
42 |
} |
|
43 |
|
|
44 |
public int getStatusCode() { |
|
45 |
return statusCode; |
|
46 |
} |
|
47 |
|
|
48 |
public Header setStatusCode(final int statusCode) { |
|
49 |
this.statusCode = statusCode; |
|
50 |
return this; |
|
51 |
} |
|
52 |
|
|
53 |
public long getTotal() { |
|
54 |
return total; |
|
55 |
} |
|
56 |
|
|
57 |
public int getPage() { |
|
58 |
return page; |
|
59 |
} |
|
60 |
|
|
61 |
public int getSize() { |
|
62 |
return size; |
|
63 |
} |
|
64 |
|
|
65 |
public Header setPage(final int page) { |
|
66 |
this.page = page; |
|
67 |
return this; |
|
68 |
} |
|
69 |
|
|
70 |
public Header setSize(final int size) { |
|
71 |
this.size = size; |
|
72 |
return this; |
|
73 |
} |
|
74 |
|
|
75 |
public Header setTotal(final long total) { |
|
76 |
this.total = total; |
|
77 |
return this; |
|
78 |
} |
|
79 |
|
|
80 |
public Queue<Throwable> getExceptions() { |
|
81 |
return exceptions; |
|
82 |
} |
|
83 |
|
|
84 |
public Header setExceptions(final Queue<Throwable> exceptions) { |
|
85 |
this.exceptions = exceptions; |
|
86 |
return this; |
|
87 |
} |
|
88 |
|
|
89 |
public List<String> getErrors() { |
|
90 |
return getExceptions().stream() |
|
91 |
.map(e -> e.getMessage()) |
|
92 |
.collect(Collectors.toList()); |
|
93 |
} |
|
94 |
|
|
95 |
public Header setErrors(final List<String> errors) { |
|
96 |
this.errors = errors; |
|
97 |
return this; |
|
98 |
} |
|
99 |
|
|
100 |
public String toJson() { |
|
101 |
return new GsonBuilder().setPrettyPrinting().create().toJson(this); |
|
102 |
} |
|
103 |
|
|
104 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/openaire/exporter/model/DatasourceResponse.java | ||
---|---|---|
1 |
package eu.dnetlib.openaire.exporter.model; |
|
2 |
|
|
3 |
import java.util.List; |
|
4 |
|
|
5 |
import com.fasterxml.jackson.annotation.JsonAutoDetect; |
|
6 |
import com.google.common.collect.Lists; |
|
7 |
import eu.dnetlib.openaire.exporter.model.datasource.DatasourceInfo; |
|
8 |
import io.swagger.annotations.ApiModel; |
|
9 |
|
|
10 |
@ApiModel |
|
11 |
@JsonAutoDetect |
|
12 |
public class DatasourceResponse extends Response { |
|
13 |
|
|
14 |
private List<DatasourceInfo> datasourceInfo = Lists.newArrayList(); |
|
15 |
|
|
16 |
public DatasourceResponse addDatasourceInfo(final DatasourceInfo datasourceInfo) { |
|
17 |
getDatasourceInfo().add(datasourceInfo); |
|
18 |
return this; |
|
19 |
} |
|
20 |
|
|
21 |
public List<DatasourceInfo> getDatasourceInfo() { |
|
22 |
return datasourceInfo; |
|
23 |
} |
|
24 |
|
|
25 |
public DatasourceResponse setDatasourceInfo(final List<DatasourceInfo> datasourceInfo) { |
|
26 |
this.datasourceInfo = datasourceInfo; |
|
27 |
return this; |
|
28 |
} |
|
29 |
|
|
30 |
} |
modules/dnet-openaire-exporter/branches/beta/src/main/java/eu/dnetlib/openaire/exporter/model/datasource/db/ActivationTerm.java | ||
---|---|---|
1 |
package eu.dnetlib.openaire.exporter.model.datasource.db; |
|
2 |
|
|
3 |
import javax.persistence.Entity; |
|
4 |
import javax.persistence.Id; |
|
5 |
import javax.persistence.Table; |
|
6 |
|
|
7 |
import com.fasterxml.jackson.annotation.JsonAutoDetect; |
|
8 |
import eu.dnetlib.openaire.exporter.model.datasource.BrowseTerm; |
|
9 |
import io.swagger.annotations.ApiModel; |
|
10 |
|
|
11 |
/** |
|
12 |
* Created by claudio on 20/04/2017. |
|
13 |
*/ |
|
14 |
@Entity |
|
15 |
@Table(name = "browse_activation") |
|
16 |
@ApiModel |
|
17 |
@JsonAutoDetect |
|
18 |
public class ActivationTerm implements Comparable<ActivationTerm>, BrowseTerm { |
|
19 |
|
|
20 |
@Id |
|
21 |
private String term; |
|
22 |
private long total; |
|
23 |
|
|
24 |
@Override |
|
25 |
public String getTerm() { |
|
26 |
return term; |
|
27 |
} |
|
28 |
|
|
29 |
public void setTerm(final String term) { |
|
30 |
this.term = term; |
|
31 |
} |
|
32 |
|
|
33 |
@Override |
|
34 |
public long getTotal() { |
|
35 |
return total; |
|
36 |
} |
|
37 |
|
|
38 |
public void setTotal(final long total) { |
|
39 |
this.total = total; |
Also available in: Unified diff