Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Java 17 #186

Merged
merged 3 commits into from
Jan 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 0 additions & 39 deletions .classpath

This file was deleted.

4 changes: 2 additions & 2 deletions .github/workflows/java-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 11
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 11
java-version: 17
- name: Build with Maven
run: mvn clean verify
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,16 @@
**/.idea
**/*iml

# Eclipse stuff
/.project
/.classpath
/.settings

# The H2 database files
**/*mv.db
**/*trace.db

### Docker ###
docker-compose-local*

pom.xml.releaseBackup
Expand Down
23 changes: 0 additions & 23 deletions .project

This file was deleted.

12 changes: 0 additions & 12 deletions .settings/.jsdtscope

This file was deleted.

6 changes: 0 additions & 6 deletions .settings/org.eclipse.core.resources.prefs

This file was deleted.

16 changes: 0 additions & 16 deletions .settings/org.eclipse.jdt.core.prefs

This file was deleted.

4 changes: 0 additions & 4 deletions .settings/org.eclipse.m2e.core.prefs

This file was deleted.

11 changes: 0 additions & 11 deletions .settings/org.eclipse.wst.common.component

This file was deleted.

11 changes: 0 additions & 11 deletions .settings/org.eclipse.wst.common.project.facet.core.xml

This file was deleted.

1 change: 0 additions & 1 deletion .settings/org.eclipse.wst.jsdt.ui.superType.container

This file was deleted.

1 change: 0 additions & 1 deletion .settings/org.eclipse.wst.jsdt.ui.superType.name

This file was deleted.

2 changes: 0 additions & 2 deletions .settings/org.eclipse.wst.validation.prefs

This file was deleted.

6 changes: 2 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Use Maven image to execute build.
FROM maven:3.6.3-openjdk-11 AS maven-build
FROM maven:3.6.3-openjdk-17 AS maven-build
RUN mkdir phoebus-olog
WORKDIR /phoebus-olog
COPY . .
Expand All @@ -10,9 +10,7 @@ RUN mvn clean install \
-Pdeployable-jar

# Use smaller openjdk image for running.
FROM openjdk:11
# apt clean is run automatically in debian-based images.
RUN apt update && apt install -y wait-for-it
FROM openjdk:17
# Run commands as user 'olog'
RUN useradd -ms /bin/bash olog
# Use previous maven-build image.
Expand Down
4 changes: 1 addition & 3 deletions Dockerfile.integrationtest
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,8 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# ------------------------------------------------------------------------------

FROM openjdk:11
FROM openjdk:17

# apt clean is run automatically in debian-based images.
RUN apt update && apt install -y wait-for-it
# Run commands as user 'olog'
RUN useradd -ms /bin/bash olog

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Olog

* Prerequisites

* JDK 11 or newer
* JDK 17 or newer
* Elastic version 8.2.x
* mongo gridfs

Expand Down
72 changes: 45 additions & 27 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<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">
<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">
<modelVersion>4.0.0</modelVersion>
<groupId>org.phoebus</groupId>
<artifactId>service-olog</artifactId>
<version>4.7.8-SNAPSHOT</version>
<version>5.0.0-SNAPSHOT</version>
<name>Phoebus Olog</name>
<description>An online logbook service that allows for the creation and retrieval of log entries.</description>
<url>https://github.com/Olog/phoebus-olog</url>
Expand Down Expand Up @@ -47,8 +48,8 @@
<connection>scm:git:git://github.com/Olog/phoebus-olog.git</connection>
<developerConnection>scm:git:https://github.com/Olog/phoebus-olog.git</developerConnection>
<url>https://github.com/Olog/phoebus-olog/tree/master</url>
<tag>HEAD</tag>
</scm>
<tag>HEAD</tag>
</scm>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand All @@ -60,6 +61,7 @@
<skipITs>true</skipITs>
<skipITCoverage>true</skipITCoverage>
<jacoco.skip>true</jacoco.skip>
<jackson.version>2.14.3</jackson.version>
</properties>

<dependencyManagement>
Expand All @@ -79,10 +81,6 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<!-- <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId>
</dependency> -->
<!-- https://mvnrepository.com/artifact/org.springframework.data/spring-data-mongodb-parent -->

<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-mongodb</artifactId>
Expand All @@ -101,13 +99,35 @@
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.13.3</version>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<version>2.13.3</version>
<version>${jackson.version}</version>
</dependency>
<!--
<dependency>
<groupId>com.fasterxml.jackson.datatype</groupId>
<artifactId>jackson-datatype-jdk8</artifactId>
<version>2.16.1</version>
</dependency>

<dependency>
<groupId>com.fasterxml.jackson.datatype</groupId>
<artifactId>jackson-datatype-jsr310</artifactId>
<version>2.16.1</version>
</dependency>

<dependency>
<groupId>com.fasterxml.jackson.module</groupId>
<artifactId>jackson-module-parameter-names</artifactId>
<version>2.16.1</version>
</dependency>
-->



<dependency>
<groupId>jakarta.json</groupId>
<artifactId>jakarta.json-api</artifactId>
Expand Down Expand Up @@ -236,7 +256,6 @@
</dependency>



</dependencies>
<build>
<!-- read properties from the pom file and add them to the application.properties -->
Expand All @@ -260,13 +279,13 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M7</version>
<version>3.2.5</version>
</plugin>
<!-- use self-contained integration tests - org.phoebus.olog.docker -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>3.2.2</version>
<version>3.2.5</version>
<configuration>
<skipITs>${skipITs}</skipITs>
<includes>
Expand All @@ -277,16 +296,17 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<version>3.12.1</version>
<configuration>
<source>11</source>
<target>11</target>
<source>17</source>
<target>17</target>
<encoding>${project.build.sourceEncoding}</encoding>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.6.1</version>
<executions>
<execution>
<id>copy</id>
Expand Down Expand Up @@ -322,7 +342,7 @@
<id>merge</id>
<phase>verify</phase>
<goals>
<goal>merge</goal>
<goal>merge</goal>
</goals>
<configuration>
<fileSets>
Expand Down Expand Up @@ -350,15 +370,10 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>2.7.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<executions>
<execution>
<id>attach-sources</id>
Expand All @@ -371,7 +386,10 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.3.0</version>
<version>3.6.3</version>
<configuration>
<doclint>-missing</doclint>
</configuration>
<executions>
<execution>
<id>attach-javadocs</id>
Expand All @@ -384,7 +402,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>3.0.0-M5</version>
<version>3.0.1</version>
<configuration>
<tagNameFormat>v@{project.version}</tagNameFormat>
<autoVersionSubmodules>true</autoVersionSubmodules>
Expand Down Expand Up @@ -413,7 +431,7 @@
<configuration>
<!-- add this to disable checking -->
<doclint>none</doclint>
<source>11</source>
<source>17</source>
</configuration>
</execution>
</executions>
Expand Down Expand Up @@ -455,7 +473,7 @@
<plugins>
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.22.0</version>
<version>3.2.2</version>
<executions>
<execution>
<goals>
Expand Down