-
Notifications
You must be signed in to change notification settings - Fork 4
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
Updated to use current version of Horreum 0.15.x #18
base: main
Are you sure you want to change the base?
Updated to use current version of Horreum 0.15.x #18
Conversation
0f9c64b
to
0211213
Compare
I have observed the creating of a HorreumClient object is flakey due to |
@whitingjr I pinged you offline, but looks like that crossed with this comment :). I will copy here; There is a HorreumResources.waitForContainerReady() method that is used to wait until the containers are ready before progressing, you can see it used in HorreumResources.startContainers() . This scans the container log, looking for a particular string, and throws an exception after a timeout. TestContainers also has a number of different waitFor strategies for pausing execution until different conditions are met if scanning the log is not sufficient. This method can be used to ensure the services are started before trying to instantiate the client, and remove the need for any retry logic |
Thanks for pointing these out. I'll replace the retry and update the branch. |
0211213
to
6e7358c
Compare
@whitingjr I have opened a PR in Horreum that removes all of the Quarkus transitive dependencies in They are not needed and will greatly simplify the transitive dependency management of the plugin. The main difference with this change is "quarkus.http.port" & "quarkus.http.host" need to be added to the map passed to |
6e7358c
to
7351706
Compare
Both properties are now added and the Quarkus transitive dependencies are no longer part of the project. |
7351706
to
a343d6c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the tests and container services look great! I think the dependencies should be cleaned up aligned to latest LTS for Jenkins, comments are inline in POM
I have also opened this PR in Horreum to simplify the container image management: Hyperfoil/Horreum#2023
@@ -27,7 +27,7 @@ THE SOFTWARE. | |||
<parent> | |||
<groupId>org.jenkins-ci.plugins</groupId> | |||
<artifactId>plugin</artifactId> | |||
<version>4.40</version> | |||
<version>4.52</version> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The current latest version is 4.85
src/test/java/jenkins/plugins/horreum/junit/HorreumTestExtension.java
Outdated
Show resolved
Hide resolved
a343d6c
to
22d3a96
Compare
There is one weakness of the test cases being separate objects. The test-suite is not able to use AfterAll annotation. It is executed for every test class which causes containers to be recycled. Docker handles shutting down running containers when the tests all cease but Podman I don't recall. Was there a reason for |
@johnaohara For me when running the test-suite a 2nd time establishing a HorreumClient object causes
In the first execution of the test goal jenkins-for-test being unpacked for booting the Jetty server causes sufficient delay for HorreumClient to authenticate. The second test goal uses the existing unpacked directory which is quicker. |
22d3a96
to
eaca4ad
Compare
I don't know the answer to this question |
do we need to do this? |
No, just declaring it now. Other environments may fail for the initial test goal. I was seeing this occassionally before waitForContainers call was added to ArtemisMQ and Horreum. In the situation this occurs again I am thinking that after waitForContainers has returned to add a retry loop to create a HorreumClient. Let's see if necessary. |
The CI is failing the build for jdk8 and jdk11. |
the project will need to align to the minimum version that the LTS jenkins version supports |
That is 11 in plugin-pom/pom.xml for 4.85 tag.
Is there any prospect of getting a JDK 11 compile targeted version for the 2 modules ? |
They should be targeting https://github.com/Hyperfoil/Horreum/blob/0.15/horreum-api/pom.xml#L13-L14 https://github.com/Hyperfoil/Horreum/blob/0.15/horreum-client/pom.xml#L18-L19 |
@whitingjr : Fix target version for |
Yes it seems to be targeted to 17.
The effective pom reveals this for horreum-api
by adding the
Shall I create a PR ? |
A PR is already merged: Hyperfoil/Horreum#2026 |
@whitingjr horreum |
@johnaohara I am seeing horreum-infra-common now causing an issue.
A test locally with horreum-infra-common module compiled to 11 has solved all the issues. |
Is that running the build with JDK 11? we don't need to run the build/tests with JDK 11, we can use JDK17+, but release should target jdk11 |
compiling with the build/test to 17 and release at 11 the error still occurs. |
what version of the JDK are you using to build with? |
Good catch. I was using 11. With 17 it is ok. |
eaca4ad
to
7f5c4a0
Compare
… raise jdk minimum version to 11.
7f5c4a0
to
bafea5f
Compare
To get the advantage of using AfterAll annotation is there any reason not to combine these separate objects into a single object ? |
@johnaohara I have updated Jenkinsfile with configuration to change the CI builds. This isn't incorporated automatically to avoid malicious changes. Is there an alternative process to reconfigure the CI ? |
I don't see why not |
I do not know how CI/CD works for this project, that is something that needs figuring out |
Fixes #17 feature request.
This PR updates the plugin to use the most recent version of Horreum libraries and api.
Testing done
Used existing JUnit test cases to ensure the operations provided are functioning as expected after the version bump.
Submitter checklist