Skip to content

Commit 7166b42

Browse files
author
Greg Meyer
authored
Merge pull request #5 from DirectProjectJavaRI/develop
Releasing 8.0.0
2 parents a0fb251 + 3d7371f commit 7166b42

File tree

10 files changed

+127
-140
lines changed

10 files changed

+127
-140
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,6 @@
2323
hs_err_pid*
2424
/.classpath
2525
/.project
26+
/target/
27+
/embedded-db/
28+
/bin/

manifest.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ applications:
33
- name: direct-config-service
44
instances: 1
55
buildpack: java_buildpack
6-
path: target/config-service-6.0-SNAPSHOT.jar
6+
path: target/config-service-6.0.1-SNAPSHOT.jar
77
timeout: 120
88
env:
99
spring.cloud.config.label: master

pom.xml

Lines changed: 56 additions & 92 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<modelVersion>4.0.0</modelVersion>
44
<groupId>org.nhind</groupId>
55
<artifactId>config-service</artifactId>
6-
<version>6.0</version>
6+
<version>8.0.0</version>
77
<packaging>jar</packaging>
88
<name>NHIN Direct Java RI config service spring boot application</name>
99
<description>NHIN Direct Java RI config service spring boot application</description>
@@ -13,14 +13,14 @@
1313
<connection>scm:git:https://github.com/DirectProjectJavaRI/config-service.git</connection>
1414
</scm>
1515
<prerequisites>
16-
<maven>3.0.0</maven>
16+
<maven>3.5.0</maven>
1717
</prerequisites>
18-
<parent>
19-
<groupId>org.springframework.boot</groupId>
20-
<artifactId>spring-boot-starter-parent</artifactId>
21-
<version>2.1.2.RELEASE</version>
22-
<relativePath />
23-
</parent>
18+
<parent>
19+
<groupId>org.springframework.boot</groupId>
20+
<artifactId>spring-boot-starter-parent</artifactId>
21+
<version>2.5.2</version>
22+
<relativePath />
23+
</parent>
2424
<developers>
2525
<developer>
2626
<name>Greg Meyer</name>
@@ -37,41 +37,42 @@
3737
<name>New BSD License</name>
3838
<url>http://nhindirect.org/BSDLicense</url>
3939
</license>
40-
</licenses>
40+
</licenses>
4141
<properties>
4242
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
43-
<camel.version>2.22.0</camel.version>
44-
</properties>
43+
<commons-net.version>3.8.0</commons-net.version>
44+
<bcprov-jdk15on.version>1.68</bcprov-jdk15on.version>
45+
</properties>
4546
<dependencyManagement>
4647
<dependencies>
4748
<dependency>
4849
<groupId>org.springframework.boot</groupId>
4950
<artifactId>spring-boot-dependencies</artifactId>
50-
<version>2.1.2.RELEASE</version>
51+
<version>2.5.2</version>
5152
<type>pom</type>
5253
<scope>import</scope>
5354
</dependency>
5455
<dependency>
5556
<groupId>io.pivotal.spring.cloud</groupId>
5657
<artifactId>spring-cloud-services-dependencies</artifactId>
57-
<version>2.0.3.RELEASE</version>
58+
<version>3.3.0</version>
5859
<type>pom</type>
5960
<scope>import</scope>
6061
</dependency>
6162
<dependency>
6263
<groupId>org.springframework.cloud</groupId>
6364
<artifactId>spring-cloud-starter-parent</artifactId>
64-
<version>Greenwich.RELEASE</version>
65+
<version>2020.0.3</version>
6566
<type>pom</type>
6667
<scope>import</scope>
6768
</dependency>
6869
</dependencies>
6970
</dependencyManagement>
7071
<dependencies>
71-
<dependency>
72+
<dependency>
7273
<groupId>org.springframework.boot</groupId>
73-
<artifactId>spring-boot-starter-data-jpa</artifactId>
74-
</dependency>
74+
<artifactId>spring-boot-starter-webflux</artifactId>
75+
</dependency>
7576
<dependency>
7677
<groupId>org.springframework.boot</groupId>
7778
<artifactId>spring-boot-starter-security</artifactId>
@@ -83,82 +84,49 @@
8384
<dependency>
8485
<groupId>org.springframework.boot</groupId>
8586
<artifactId>spring-boot-starter-actuator</artifactId>
87+
</dependency>
88+
<dependency>
89+
<groupId>org.springframework.boot</groupId>
90+
<artifactId>spring-boot-starter-data-r2dbc</artifactId>
8691
</dependency>
8792
<dependency>
8893
<groupId>org.springframework.cloud</groupId>
89-
<artifactId>spring-cloud-starter-config</artifactId>
90-
<exclusions>
91-
<exclusion>
92-
<groupId>org.bouncycastle</groupId>
93-
<artifactId>bcpkix-jdk15on</artifactId>
94-
</exclusion>
95-
</exclusions>
94+
<artifactId>spring-cloud-starter-config</artifactId>
9695
</dependency>
97-
<dependency>
98-
<groupId>org.springframework.cloud</groupId>
99-
<artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
100-
</dependency>
10196
<dependency>
102-
<groupId>javax.inject</groupId>
103-
<artifactId>javax.inject</artifactId>
104-
<version>1</version>
105-
</dependency>
97+
<groupId>org.springframework.cloud</groupId>
98+
<artifactId>spring-cloud-starter-bootstrap</artifactId>
99+
</dependency>
106100
<dependency>
107101
<groupId>io.pivotal.spring.cloud</groupId>
108-
<artifactId>spring-cloud-services-starter-config-client</artifactId>
109-
<exclusions>
110-
<exclusion>
111-
<groupId>org.codehaus.jackson</groupId>
112-
<artifactId>jackson-mapper-asl</artifactId>
113-
</exclusion>
114-
</exclusions>
115-
</dependency>
102+
<artifactId>spring-cloud-services-starter-config-client</artifactId>
103+
</dependency>
116104
<dependency>
117105
<groupId>org.nhind</groupId>
118106
<artifactId>config-service-jar</artifactId>
119-
<version>6.0</version>
107+
<version>8.0.0</version>
120108
</dependency>
121109
<dependency>
122110
<groupId>org.nhind</groupId>
123111
<artifactId>direct-common</artifactId>
124-
<version>6.0</version>
125-
</dependency>
126-
<dependency>
127-
<groupId>org.apache.camel</groupId>
128-
<artifactId>camel-spring-boot-starter</artifactId>
129-
<version>${camel.version}</version>
130-
</dependency>
131-
<dependency>
132-
<groupId>org.apache.camel</groupId>
133-
<artifactId>camel-core</artifactId>
134-
<version>${camel.version}</version>
135-
</dependency>
136-
<dependency>
137-
<groupId>org.apache.camel</groupId>
138-
<artifactId>camel-spring</artifactId>
139-
<version>${camel.version}</version>
140-
</dependency>
141-
<dependency>
142-
<groupId>org.apache.camel</groupId>
143-
<artifactId>camel-mina</artifactId>
144-
<version>${camel.version}</version>
145-
</dependency>
112+
<version>8.0.0</version>
113+
</dependency>
146114
<dependency>
147115
<groupId>commons-net</groupId>
148116
<artifactId>commons-net</artifactId>
149-
<version>3.6</version>
117+
<version>${commons-net.version}</version>
150118
</dependency>
151119
<dependency>
152120
<groupId>org.bouncycastle</groupId>
153121
<artifactId>bcprov-jdk15on</artifactId>
154-
<version>1.60</version>
122+
<version>${bcprov-jdk15on.version}</version>
155123
</dependency>
156124
<!-- Database Drivers For Connectivity Options -->
157125
<dependency>
158126
<groupId>com.h2database</groupId>
159127
<artifactId>h2</artifactId>
160128
<scope>runtime</scope>
161-
</dependency>
129+
</dependency>
162130
<dependency>
163131
<groupId>org.apache.derby</groupId>
164132
<artifactId>derby</artifactId>
@@ -173,7 +141,22 @@
173141
<groupId>org.postgresql</groupId>
174142
<artifactId>postgresql</artifactId>
175143
<scope>runtime</scope>
176-
</dependency>
144+
</dependency>
145+
<dependency>
146+
<groupId>dev.miku</groupId>
147+
<artifactId>r2dbc-mysql</artifactId>
148+
<scope>runtime</scope>
149+
</dependency>
150+
<dependency>
151+
<groupId>io.r2dbc</groupId>
152+
<artifactId>r2dbc-postgresql</artifactId>
153+
<scope>runtime</scope>
154+
</dependency>
155+
<dependency>
156+
<groupId>io.r2dbc</groupId>
157+
<artifactId>r2dbc-h2</artifactId>
158+
<scope>runtime</scope>
159+
</dependency>
177160
</dependencies>
178161
<build>
179162
<plugins>
@@ -210,31 +193,13 @@
210193
</plugin>
211194
<plugin>
212195
<groupId>org.springframework.boot</groupId>
213-
<artifactId>spring-boot-maven-plugin</artifactId>
214-
<!-- Spring is not very good at finding Entity objects in jar files that are nested
215-
in jar files. This will explode out the contents of the org.nhind library at runtime
216-
so the entity objects can be found and managed
217-
-->
218-
<configuration>
219-
<mainClass>org.nhindirect.config.boot.ConfigServiceApplication</mainClass>
220-
<requiresUnpack>
221-
<dependency>
222-
<groupId>org.nhind</groupId>
223-
<artifactId>config-store</artifactId>
224-
</dependency>
225-
<dependency>
226-
<groupId>org.nhind</groupId>
227-
<artifactId>config-service-jar</artifactId>
228-
</dependency>
229-
</requiresUnpack>
230-
</configuration>
196+
<artifactId>spring-boot-maven-plugin</artifactId>
231197
</plugin>
232198
<plugin>
233199
<groupId>org.apache.maven.plugins</groupId>
234200
<artifactId>maven-javadoc-plugin</artifactId>
235-
<version>2.6.1</version>
236201
<configuration>
237-
<additionalparam>-Xdoclint:none</additionalparam>
202+
<additionalJOption>-Xdoclint:none</additionalJOption>
238203
<charset>UTF-8</charset>
239204
<docencoding>UTF-8</docencoding>
240205
<docfilessubdirs>true</docfilessubdirs>
@@ -253,7 +218,7 @@
253218
</execution>
254219
</executions>
255220
</plugin>
256-
<!-- for releases only
221+
<!-- for releases only
257222
<plugin>
258223
<groupId>org.apache.maven.plugins</groupId>
259224
<artifactId>maven-gpg-plugin</artifactId>
@@ -267,22 +232,20 @@
267232
</execution>
268233
</executions>
269234
</plugin>
270-
-->
235+
-->
271236
</plugins>
272237
</build>
273238
<reporting>
274239
<plugins>
275240
<plugin>
276241
<groupId>org.apache.maven.plugins</groupId>
277242
<artifactId>maven-project-info-reports-plugin</artifactId>
278-
<version>2.9</version>
279243
</plugin>
280244
<plugin>
281245
<groupId>org.apache.maven.plugins</groupId>
282246
<artifactId>maven-javadoc-plugin</artifactId>
283-
<version>2.6.1</version>
284247
<configuration>
285-
<additionalparam>-Xdoclint:none</additionalparam>
248+
<additionalJOption>-Xdoclint:none</additionalJOption>
286249
<charset>UTF-8</charset>
287250
<docencoding>UTF-8</docencoding>
288251
<docfilessubdirs>true</docfilessubdirs>
@@ -306,6 +269,7 @@
306269
<plugin>
307270
<groupId>org.apache.maven.plugins</groupId>
308271
<artifactId>maven-jxr-plugin</artifactId>
272+
<version>3.1.1</version>
309273
</plugin>
310274
<plugin>
311275
<groupId>org.codehaus.mojo</groupId>
Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,24 @@
11
package org.nhindirect.config.boot;
22

33
import org.springframework.boot.SpringApplication;
4+
import org.springframework.boot.WebApplicationType;
45
import org.springframework.boot.autoconfigure.SpringBootApplication;
5-
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
66
import org.springframework.context.annotation.ComponentScan;
7+
import org.springframework.data.r2dbc.repository.config.EnableR2dbcRepositories;
8+
import org.springframework.scheduling.annotation.EnableScheduling;
79

810

911
@ComponentScan({"org.nhindirect.config"})
10-
@SpringBootApplication
11-
@EnableEurekaClient
12+
@SpringBootApplication()
13+
@EnableR2dbcRepositories("org.nhindirect.config.repository")
14+
@EnableScheduling
1215
public class ConfigServiceApplication
1316
{
1417
public static void main(String[] args)
1518
{
16-
SpringApplication.run(ConfigServiceApplication.class, args);
19+
final SpringApplication app = new SpringApplication(ConfigServiceApplication.class);
20+
app.setWebApplicationType(WebApplicationType.REACTIVE);
21+
app.run(args);
1722
}
1823

1924
}
Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,32 @@
11
package org.nhindirect.config.boot;
22

33
import org.springframework.context.annotation.Bean;
4-
import org.springframework.security.config.annotation.web.reactive.EnableWebFluxSecurity;
4+
import org.springframework.context.annotation.Configuration;
55
import org.springframework.security.config.web.server.ServerHttpSecurity;
66
import org.springframework.security.web.server.SecurityWebFilterChain;
77

8-
@EnableWebFluxSecurity
9-
public class WebSecurityConfiguration
8+
@Configuration
9+
public class WebSecurityConfiguration
1010
{
1111
@Bean
1212
public SecurityWebFilterChain springSecurityFilterChain(ServerHttpSecurity http)
1313
{
14-
http.csrf().disable();
1514

16-
return http.build();
15+
http.csrf().disable()
16+
.authorizeExchange()
17+
.pathMatchers("/domains/**", "/address/**", "/anchor/**",
18+
"/certificate/**", "/certpolicy/**", "/dns/**",
19+
"/setting/**", "/trustbundle/**").permitAll()
20+
.anyExchange().authenticated()
21+
.and()
22+
.httpBasic()
23+
.and()
24+
.formLogin().disable();
25+
26+
27+
28+
return http.build();
1729
}
18-
}
1930

31+
32+
}

src/main/resources/application.properties

Lines changed: 0 additions & 5 deletions
This file was deleted.

src/main/resources/application.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# automatically expand info properties from the Maven project using resource filtering
2+
info:
3+
build:
4+
artifact: '@project.artifactId@'
5+
name: '@project.name@'
6+
description: '@project.description@'
7+
version: '@project.version@'
8+
9+
spring:
10+
#Default username and password
11+
security:
12+
basic.enabled: true
13+
user:
14+
name: admin
15+
password: '{bcrypt}$2a$04$WQsYXSBOnycO1/7E9bKUVevWX3.Gxv2V6ZfYx9UKoy3lm9.4TjU7e'
16+
17+
#Default H2 Database Settings. This is not recommended for production use
18+
#and not fit for purpose for ephemeral deployments (you are almost guaranteed to lose your data if
19+
#using an ephemeral environment)
20+
r2dbc:
21+
url: r2dbc:h2:file:///./embedded-db/nhindconfig
22+
username: sa
23+
password:
24+
25+
sql.init.platform: h2
26+
sql.init.mode: ALWAYS

0 commit comments

Comments
 (0)