diff --git a/.github/workflows/maven-adapter-release.yml b/.github/workflows/maven-adapter-release.yml index bfb6d3e6c..8cf67c203 100644 --- a/.github/workflows/maven-adapter-release.yml +++ b/.github/workflows/maven-adapter-release.yml @@ -2,7 +2,7 @@ name: Create Maven adapter release on: push: tags: - - '*_*_*' + - '*_*' jobs: build: name: Build release @@ -55,20 +55,10 @@ jobs: } ] - run: mvn -B install -DskipTests - - uses: actions/setup-java@v2 - with: - java-version: ${{steps.split.outputs._2}} - distribution: adopt - - name: Deploy adapter with java > 8 - run: mvn deploy -Partipie,publish,sonatype,gpg-sign -DskipTests --errors + - run: mvn deploy -Partipie,publish,sonatype,gpg-sign -DskipTests --errors working-directory: ${{steps.split.outputs._0}} - if: ${{steps.split.outputs._2 != '8'}} env: MAVEN_OPTS: --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang.reflect=ALL-UNNAMED --add-opens=java.base/java.text=ALL-UNNAMED --add-opens=java.desktop/java.awt.font=ALL-UNNAMED - - name: Deploy adapter with java 8 - run: mvn deploy -Partipie,publish,sonatype,gpg-sign -DskipTests --errors - working-directory: ${{steps.split.outputs._0}} - if: ${{steps.split.outputs._2 == '8'}} - name: Create Github Release id: create_release uses: actions/create-release@v1 diff --git a/README.md b/README.md index 80a8f6910..1eec7cb81 100644 --- a/README.md +++ b/README.md @@ -140,9 +140,9 @@ git push --tags origin ``` Also, each adapter can be released into Maven Central individually. To do that, push git tag of the following format: ```text -[adapter-name]_[version]_[java-version] -rpm-adapter_v1.2.3_8 +[adapter-name]_[version] +rpm-adapter_v1.2.3 ``` On this tag, GitHub action [maven-adapter-release.yml](.github%2Fworkflows%2Fmaven-adapter-release.yml) will run to -release specified adapter using specified java version. Note, that required Java Version is also set in adapters' pom -files and should correspond to version in release tag. +release specified adapter. Note, that some of the adapters should be compatible with java 8. To achieve that, we use +[--release=8](https://www.baeldung.com/java-compiler-release-option) option for the main code. diff --git a/artipie-core/src/main/java/com/artipie/security/perms/UserPermissions.java b/artipie-core/src/main/java/com/artipie/security/perms/UserPermissions.java index b239cc3bf..66ad2676a 100644 --- a/artipie-core/src/main/java/com/artipie/security/perms/UserPermissions.java +++ b/artipie-core/src/main/java/com/artipie/security/perms/UserPermissions.java @@ -4,7 +4,6 @@ */ package com.artipie.security.perms; -import java.io.Serial; import java.security.Permission; import java.security.PermissionCollection; import java.util.Enumeration; @@ -48,7 +47,6 @@ public final class UserPermissions extends PermissionCollection { /** * Required serial. */ - @Serial private static final long serialVersionUID = -7546496571951236695L; /** diff --git a/artipie-main/pom.xml b/artipie-main/pom.xml index d694710ed..b01db1203 100644 --- a/artipie-main/pom.xml +++ b/artipie-main/pom.xml @@ -275,6 +275,17 @@ SOFTWARE. test + + + + org.apache.maven.plugins + maven-compiler-plugin + + 21 + + + + docker-build @@ -340,19 +351,11 @@ SOFTWARE. true - - org.apache.maven.plugins - maven-compiler-plugin - - ${maven.compiler.source} - ${maven.compiler.target} - - org.apache.maven.plugins maven-javadoc-plugin - ${maven.compiler.source} + 21 diff --git a/artipie-main/src/main/resources/example/artipie.yaml b/artipie-main/src/main/resources/example/artipie.yaml index c0a43bf02..2fcf0952f 100644 --- a/artipie-main/src/main/resources/example/artipie.yaml +++ b/artipie-main/src/main/resources/example/artipie.yaml @@ -4,10 +4,14 @@ meta: path: /var/artipie/repo credentials: - type: env + - type: github + - type: artipie + policy: + type: artipie + storage: + type: fs + path: /var/artipie/security base_url: http://central.artipie.com/ - crontab: - - path: C:\Users\g00563573\IdeaProjects\artipie\data\del_docker.rb - cronexp: "*/1 * * * * ?" metrics: port: 8087 endpoint: "/metrics" diff --git a/composer-adapter/pom.xml b/composer-adapter/pom.xml index 1c8397bdf..770175435 100644 --- a/composer-adapter/pom.xml +++ b/composer-adapter/pom.xml @@ -34,10 +34,6 @@ SOFTWARE. jar composer-files Turns your files/objects into PHP Composer artifacts - - 8 - 8 - com.google.guava diff --git a/conan-adapter/pom.xml b/conan-adapter/pom.xml index 34c84467a..de5b935a4 100644 --- a/conan-adapter/pom.xml +++ b/conan-adapter/pom.xml @@ -31,10 +31,6 @@ SOFTWARE. conan-adapter 1.0-SNAPSHOT - - 8 - 8 - com.artipie diff --git a/conda-adapter/pom.xml b/conda-adapter/pom.xml index 3aba0401d..6e6492768 100644 --- a/conda-adapter/pom.xml +++ b/conda-adapter/pom.xml @@ -34,10 +34,6 @@ SOFTWARE. conda-adapter Turns your files/objects into conda repository 2021 - - 1.8 - 1.8 - com.artipie diff --git a/debian-adapter/pom.xml b/debian-adapter/pom.xml index 7075254e1..9a0302049 100644 --- a/debian-adapter/pom.xml +++ b/debian-adapter/pom.xml @@ -36,8 +36,6 @@ SOFTWARE. Debian adapter 2020 - 1.8 - 1.8 1.70 1.29 diff --git a/files-adapter/src/test/java/com/artipie/files/FileProxySliceITCase.java b/files-adapter/src/test/java/com/artipie/files/FileProxySliceITCase.java index dff9a970e..a0ec953dc 100644 --- a/files-adapter/src/test/java/com/artipie/files/FileProxySliceITCase.java +++ b/files-adapter/src/test/java/com/artipie/files/FileProxySliceITCase.java @@ -21,7 +21,9 @@ import java.nio.charset.StandardCharsets; import java.util.Queue; import java.util.concurrent.ConcurrentLinkedDeque; +import java.util.concurrent.TimeUnit; import org.apache.http.client.utils.URIBuilder; +import org.awaitility.Awaitility; import org.hamcrest.MatcherAssert; import org.hamcrest.core.IsEqual; import org.junit.jupiter.api.AfterEach; @@ -131,7 +133,7 @@ void savesDataInCache() throws URISyntaxException { new BlockingStorage(cache).value(new Key.From("any")), new IsEqual<>(data) ); - MatcherAssert.assertThat("Event was added to queue", events.size() == 1); + Awaitility.await().atMost(30, TimeUnit.SECONDS).until(() -> events.size() == 1); final ArtifactEvent item = events.element(); MatcherAssert.assertThat( item.artifactName(), diff --git a/gem-adapter/pom.xml b/gem-adapter/pom.xml index 4eb804f63..4e3f1eff2 100644 --- a/gem-adapter/pom.xml +++ b/gem-adapter/pom.xml @@ -34,10 +34,6 @@ SOFTWARE. gem-adapter An Artipie adapter for Ruby Gem packages 2020 - - 8 - 8 - com.artipie diff --git a/helm-adapter/pom.xml b/helm-adapter/pom.xml index fff8b74e3..ee5ae3232 100644 --- a/helm-adapter/pom.xml +++ b/helm-adapter/pom.xml @@ -32,10 +32,6 @@ SOFTWARE. helm-adapter 1.0-SNAPSHOT helm-adapter - - 8 - 8 - com.artipie diff --git a/hexpm-adapter/pom.xml b/hexpm-adapter/pom.xml index 0931d7ebf..ae375e4e4 100644 --- a/hexpm-adapter/pom.xml +++ b/hexpm-adapter/pom.xml @@ -61,4 +61,15 @@ SOFTWARE. test + + + + org.apache.maven.plugins + maven-compiler-plugin + + 21 + + + + diff --git a/maven-adapter/pom.xml b/maven-adapter/pom.xml index 707691a97..d128c22d6 100644 --- a/maven-adapter/pom.xml +++ b/maven-adapter/pom.xml @@ -75,5 +75,14 @@ SOFTWARE. false + + + org.apache.maven.plugins + maven-compiler-plugin + + 21 + + + diff --git a/npm-adapter/pom.xml b/npm-adapter/pom.xml index e316c4f4e..6b25d3818 100644 --- a/npm-adapter/pom.xml +++ b/npm-adapter/pom.xml @@ -35,10 +35,6 @@ SOFTWARE. npm-adapter Turns your files/objects into NPM artifacts 2019 - - 8 - 8 - org.apache.commons diff --git a/nuget-adapter/pom.xml b/nuget-adapter/pom.xml index 9cf282834..24db8ff64 100644 --- a/nuget-adapter/pom.xml +++ b/nuget-adapter/pom.xml @@ -35,10 +35,6 @@ SOFTWARE. nuget-adapter Turns your files/objects into NuGet artifacts 2020 - - 8 - 8 - com.artipie diff --git a/pom.xml b/pom.xml index be8b493c6..51817f2d2 100644 --- a/pom.xml +++ b/pom.xml @@ -75,8 +75,6 @@ SOFTWARE. https://github.com/artipie/artipie - 21 - 21 artipie/artipie ${project.basedir}/../LICENSE.header v1.16.0 @@ -235,6 +233,27 @@ SOFTWARE. + + + org.apache.maven.plugins + maven-compiler-plugin + + 8 + + + + test-compile + process-test-sources + + testCompile + + + 21 + + + + + diff --git a/rpm-adapter/pom.xml b/rpm-adapter/pom.xml index d52eb9dd8..0ba5c4898 100644 --- a/rpm-adapter/pom.xml +++ b/rpm-adapter/pom.xml @@ -34,10 +34,6 @@ SOFTWARE. rpm-adapter Turns your files/objects into RPM artifacts 2019 - - 8 - 8 - com.artipie