-
Notifications
You must be signed in to change notification settings - Fork 148
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
Added basic develocity setup #25322 #25324
Conversation
@arjantijms can you link helpdesk ticket for secrets creation, please? |
Unfortunately, as this change comes from non-committer the Jenkinsfile from target branch was used during the build for PR (and not the modified one). Now we need
|
If you wish to participate in the evaluation process, please open a ticket in the eclipse helpdesk. |
@dmatej as the project lead, can you take a look? |
@pzygielo Can you create that helpdesk ticket? Or tell me what exactly do we need? Is it something like this? I have doubts about the caching as the project is large and has significant technical debt and we already had issues with caching on Jenkins. Maybe it was be better to start the discussion with the community before merging it, and do some experiments to avoid blocking the whole project. But we already made this step, so lets resolve this and we will see. What other leaders think about it? @hs536 @smillidge |
@dmatej To be clear, this PR only connects the project, caching (both local and remote) is left disabled, so that can be done separately. As for the issue to get credentials: yes, this is exactly what is needed :) I did run some tests with the local cache and got very nice results, though. Here is a scan from the experiment, where 54% of the time was saved + there are some tweaks I can do to further increase that number (and decrease the build time). Note that Develocity Build Cache works a bit different thatn Apache Maven Build Cache, as Develocity one works on a goal level, whereas Maven cache works on a project level. We have lots of experience caching large and complex projects, so I'd be happy to help out and resolve any issues that pop up. |
@ribafish Is it possible to disable the maven extension locally by default? My local builds slowed to 42 seconds from 36 after I rebased to current master. I tried several times, seems that the slowdown is visible - I do a lot of iterations, so any slowdown is visible in long term. I am not sure if the change has any effect on "full" builds, probably not as they are not so parallelized.
|
And the documentation build is green. I'd think that this should not be affected, https://ci.eclipse.org/glassfish/job/glassfish-website-publish-docs/1505/console, yet:
and the site seems to remain not updated - https://glassfish.org/docs/latest/administration-guide.html: |
@pzygielo - This must be configured on the Jenkins instance, which is one of the reasons you need to open a ticket in the eclipse helpdesk. As for why it's affected - the extension is applied on the project level, which means that any build will have at applied. In order to publish scans, you need to have credentials configured, but if you don't, the scan just won't get published. This is an access error, which is why this build is affected. @dmatej - how confident are you that this is because of Develocity? I can't reproduce it locally and I get varied build times(those are obviously with the Develocity extension) with no changes in between. Builds without it also vary from 2m35s to 3m06s, similar to the builds with the extension. Note: you can also set up publishing scans from local builds by authenticating to develocity-staging.eclipse.org by running |
I'm completely not worried about scans being or not being published. But I'm bothered by updated documentation not being published to glassfish site and whole Jenkins PR build not working at all.
As was said already -- in current state of Jenkinsfile -- the build is not even starting. |
The last commit before merging this PR:
|
@pzygielo I see the log for the documentation ... I am not sure if credentials can resolve this, should we revert it? |
Issue in GitLab created: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/issues/5546 |
Unsure indeed - as it's separate job, not controlled by Jenkinsfile modified here. Perhaps the job has to reference secrets as well? If so - which other jobs need that as well? Maybe release job will also be not happy with
and not being prepared for that. |
To expand a bit about what is causing the issue with the documentation above: The extension is working with some files in the user home folder, to which it expects to have the access to (by the user running the build). Since the Jenkins instance is configured so that the user running doesn't have permissions to modify those files, the build pipeline fails (this will get fixed now that there's an open ticket). It has nothing to do with credentials or secrets/vaults. |
@dmatej about the slowdown: We'd really like to troubleshoot this. Could you create a build scan of a build with the extension applied (for local builds you just need to authenticate once)? Also, what do you mean by There is a marginal overhead to capture the data and we do not need to synchronize in case of parallel builds, as we do most of the work on a specific worker thread. |
I was wrong in #25324 (comment), as latest is apparently for latest release, but https://glassfish.org/docs/SNAPSHOT/security-guide.html is fine |
Yes, here: https://github.com/eclipse-ee4j/glassfish-build-maven-plugin/blob/master/src/main/java/org/glassfish/build/GlassFishJarLifecycle.java
I would still welcome a way to disable/enable it so it would be active only when we do want that (ie on CI). |
This was
|
@dmatej Hm, it doesn't look like the custom Maven lifecycle configures anything that would affect the performance when used together with the Develocity extension. I created a script and Github Actions workflow to run some tests and I can confirm that with the Develocity extension, the average runtime when running This speedup is even more visible when tests are executed (running To enable caching, I prepared 3 chained PRs: |
This PR will enable you to publish Build Scans to develocity-staging.eclipse.org as explained in the issue #25322.
Description
This PR publishes a build scan for every CI build (once CI credentials are created) and for every local build from an authenticated Eclipse committer. The build will not fail if publishing fails. Local and remote caching was left disabled on this PR by design so that the build is not affected by this change.
The build scans of the Eclipse Glassfish project are published to the Develocity instance at develocity-staging.eclipse.org, hosted by the Eclipse Foundation and run in partnership between the Eclipse and Gradle. This Develocity instance has all features and extensions enabled and is freely available for use by the Eclipse Glassfish project and all other Eclipse projects.
On this Develocity instance, Eclipse Glassfish will have access not only to all of the published build scans but also to other aggregate data features such as:
This will also enable you to (optionally) use build time optimization features, such as (remote) build caching and Predictive Test Selection.
More information can be read in the Eclipse announcement. This is the first part of Develocity integration issue no. #25322. The second part, if you opt for it, would be to enable caching for the project.
Please let me know if there are any questions about the value of Develocity or the changes in this pull request and I’d be happy to address them. If your project is interested in being a part of this initiative, please reach out to Eclipse infra by filling out a helpdesk ticket to get the CI credentials.
Locally, you can authenticate by running
mvn develocity:provision-access-key
. More info available here