Revision 58953
Added by Konstantina Galouni almost 4 years ago
modules/uoa-monitor-service/trunk/src/main/java/eu/dnetlib/uoamonitorservice/UoaMonitorServiceApplication.java | ||
---|---|---|
7 | 7 |
import org.springframework.boot.context.properties.EnableConfigurationProperties; |
8 | 8 |
import org.springframework.context.annotation.PropertySource; |
9 | 9 |
import org.springframework.context.annotation.PropertySources; |
10 |
|
|
11 |
@SpringBootApplication(scanBasePackages = {"eu.dnetlib.uoamonitorservice", "eu.dnetlib.uoahelptexts"})
|
|
10 |
//uoahelptexts |
|
11 |
@SpringBootApplication(scanBasePackages = {"eu.dnetlib.uoamonitorservice", "eu.dnetlib.uoaadmintoolslibrary"})
|
|
12 | 12 |
@PropertySources({ |
13 | 13 |
@PropertySource("classpath:monitorservice.properties"), |
14 |
@PropertySource(value = "file:/usr/share/tomcat7/lib/dnet-override.properties", ignoreResourceNotFound = true), |
|
15 |
@PropertySource(value = "file:/var/lib/tomcat_dnet/8380/lib/dnet-override.properties", ignoreResourceNotFound = true), |
|
16 |
@PropertySource(value = "file:/var/lib/tomcat8/lib/dnet-override.properties", ignoreResourceNotFound = true) |
|
17 |
|
|
14 |
// @PropertySource(value = "file:/usr/share/tomcat7/lib/dnet-override.properties", ignoreResourceNotFound = true),
|
|
15 |
// @PropertySource(value = "file:/var/lib/tomcat_dnet/8380/lib/dnet-override.properties", ignoreResourceNotFound = true),
|
|
16 |
// @PropertySource(value = "file:/var/lib/tomcat8/lib/dnet-override.properties", ignoreResourceNotFound = true)
|
|
17 |
@PropertySource("classpath:dnet-override.properties") |
|
18 | 18 |
}) |
19 | 19 |
|
20 | 20 |
@EnableConfigurationProperties({SecurityConfig.class, MongoConfig.class}) |
modules/uoa-monitor-service/trunk/src/main/java/eu/dnetlib/uoamonitorservice/controllers/EmailController.java | ||
---|---|---|
1 | 1 |
package eu.dnetlib.uoamonitorservice.controllers; |
2 | 2 |
|
3 |
import eu.dnetlib.uoahelptexts.emailSender.EmailSender; |
|
4 |
import eu.dnetlib.uoahelptexts.entities.EmailRecaptcha; |
|
5 |
import eu.dnetlib.uoahelptexts.entities.Email; |
|
6 |
import eu.dnetlib.uoahelptexts.handlers.InvalidReCaptchaException; |
|
7 |
import eu.dnetlib.uoahelptexts.recaptcha.VerifyRecaptcha; |
|
3 |
//import eu.dnetlib.uoahelptexts.emailSender.EmailSender; |
|
4 |
//import eu.dnetlib.uoahelptexts.entities.EmailRecaptcha; |
|
5 |
//import eu.dnetlib.uoahelptexts.entities.Email; |
|
6 |
//import eu.dnetlib.uoahelptexts.handlers.InvalidReCaptchaException; |
|
7 |
//import eu.dnetlib.uoahelptexts.recaptcha.VerifyRecaptcha; |
|
8 |
import eu.dnetlib.uoaadmintoolslibrary.emailSender.EmailSender; |
|
9 |
import eu.dnetlib.uoaadmintoolslibrary.entities.email.Email; |
|
10 |
import eu.dnetlib.uoaadmintoolslibrary.entities.email.EmailRecaptcha; |
|
11 |
import eu.dnetlib.uoaadmintoolslibrary.handlers.InvalidReCaptchaException; |
|
12 |
import eu.dnetlib.uoaadmintoolslibrary.recaptcha.VerifyRecaptcha; |
|
8 | 13 |
import org.apache.log4j.Logger; |
9 | 14 |
import org.springframework.beans.factory.annotation.Autowired; |
10 | 15 |
import org.springframework.web.bind.annotation.*; |
modules/uoa-monitor-service/trunk/src/main/java/eu/dnetlib/uoamonitorservice/configuration/mongo/MongoConnection.java | ||
---|---|---|
14 | 14 |
import org.springframework.data.mongodb.repository.config.EnableMongoRepositories; |
15 | 15 |
|
16 | 16 |
import java.util.Collections; |
17 |
|
|
17 |
//"uoahelptexts" |
|
18 | 18 |
@Configuration |
19 |
@EnableMongoRepositories(basePackages = {"eu.dnetlib.uoamonitorservice.dao", "eu.dnetlib.uoahelptexts.dao"})
|
|
19 |
@EnableMongoRepositories(basePackages = {"eu.dnetlib.uoamonitorservice.dao", "eu.dnetlib.uoaadmintoolslibrary.dao"})
|
|
20 | 20 |
public class MongoConnection { |
21 | 21 |
|
22 | 22 |
@Autowired |
modules/uoa-monitor-service/trunk/pom.xml | ||
---|---|---|
62 | 62 |
<artifactId>gson</artifactId> |
63 | 63 |
<version>2.8.2</version> |
64 | 64 |
</dependency> |
65 |
<!-- <dependency>--> |
|
66 |
<!-- <groupId>eu.dnetlib</groupId>--> |
|
67 |
<!-- <artifactId>uoa-help-texts-library</artifactId>--> |
|
68 |
<!-- <version>2.0.0-SNAPSHOT</version>--> |
|
69 |
<!-- </dependency>--> |
|
65 | 70 |
<dependency> |
66 | 71 |
<groupId>eu.dnetlib</groupId> |
67 |
<artifactId>uoa-help-texts-library</artifactId>
|
|
68 |
<version>2.0.0-SNAPSHOT</version>
|
|
72 |
<artifactId>uoa-admin-tools-library</artifactId>
|
|
73 |
<version>1.0.0-SNAPSHOT</version>
|
|
69 | 74 |
</dependency> |
75 |
<dependency> |
|
76 |
<groupId>org.springframework.boot</groupId> |
|
77 |
<artifactId>spring-boot-starter-test</artifactId> |
|
78 |
<scope>test</scope> |
|
79 |
</dependency> |
|
70 | 80 |
</dependencies> |
71 | 81 |
|
72 | 82 |
<build> |
Also available in: Unified diff
[Trunk | Monitor Service]:
1. pom.xml: Comment dependency of "uoa-help-texts-library" and add dependency of "uoa-admin-tools-library" | Add dependency of "spring-boot-starter-test".
2. MongoConnection.java: Replace basePackage "eu.dnetlib.uoahelptexts.dao" with "eu.dnetlib.uoaadmintoolslibrary.dao".
3. EmailController.java: Import from " eu.dnetlib.uoaadmintoolslibrary" instead of "eu.dnetlib.uoahelptexts".
4. UoaMonitorServiceApplication.java: Replace scanBasePackage "eu.dnetlib.uoahelptexts" with "eu.dnetlib.uoaadmintoolslibrary" | Add @PropertySource("classpath:dnet-override.properties".