Skip to content

Conversation

breskeby
Copy link
Contributor

@breskeby breskeby commented Oct 8, 2025

This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

@breskeby breskeby requested a review from a team as a code owner October 8, 2025 16:01
@breskeby breskeby added >non-issue :Delivery/Build Build or test infrastructure Team:Delivery Meta label for Delivery team auto-backport Automatically create backport pull requests when merged v8.19.6 v9.1.6 v9.0.9 v8.18.9 v9.2.1 v9.3.0 labels Oct 8, 2025
@breskeby breskeby self-assigned this Oct 8, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-delivery (Team:Delivery)

var runtimeConfiguration = project.getConfigurations().getByName(JavaPlugin.RUNTIME_CLASSPATH_CONFIGURATION_NAME);
t.getRuntimeArtifacts().set(project.getProviders().provider(() -> runtimeConfiguration.getIncoming().getArtifacts()));
t.getRuntimeArtifacts()
.set(project.getProviders().provider(() -> createNonTransitiveArtifactsView(runtimeConfiguration).getArtifacts()));
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We only care about the direct dependencies here

* </ul>
*/
public abstract class DependenciesInfoTask extends ConventionTask {
@CacheableTask
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since we removed the convention mapping we can make that task cacheable

'https://oss-dependencies.elastic.co/red-hat-universal-base-image-minimal/9/ubi-minimal-9-source.tar.gz'
]
additionalLines << rhelUbiFields.join(',')
doLast {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just another safety net to capture suspicious change in behaviour

@breskeby breskeby force-pushed the fix-dependency-reporting branch 2 times, most recently from 8d4d7c6 to 46e91f1 Compare October 9, 2025 07:53
Comment on lines +101 to +102
.map(mcaId -> (ModuleComponentArtifactIdentifier) mcaId)
.map(it -> it.getComponentIdentifier())
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do I understand correctly this part was the root cause of missing dependencies in the report? Did Gradle change something in the identifiers hierarchy?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exactly

This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task
@breskeby breskeby force-pushed the fix-dependency-reporting branch from 4855ac1 to f252c2d Compare October 9, 2025 09:53
Copy link
Contributor

@jozala jozala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.
Thanks for adding comments. It helps to understand the changes more quickly.

@breskeby breskeby added the auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) label Oct 9, 2025
@breskeby breskeby merged commit f74406d into elastic:main Oct 9, 2025
33 of 34 checks passed
@breskeby breskeby deleted the fix-dependency-reporting branch October 9, 2025 19:14
breskeby added a commit to breskeby/elasticsearch that referenced this pull request Oct 9, 2025
This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task
@elasticsearchmachine
Copy link
Collaborator

💔 Backport failed

Status Branch Result
8.19 Commit could not be cherrypicked due to conflicts
9.1 Commit could not be cherrypicked due to conflicts
9.0 Commit could not be cherrypicked due to conflicts
8.18 Commit could not be cherrypicked due to conflicts
9.2

You can use sqren/backport to manually backport by running backport --upstream elastic/elasticsearch --pr 136209

breskeby added a commit to breskeby/elasticsearch that referenced this pull request Oct 9, 2025
This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task

(cherry picked from commit f74406d)
breskeby added a commit to breskeby/elasticsearch that referenced this pull request Oct 9, 2025
This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task

(cherry picked from commit f74406d)

# Conflicts:
#	x-pack/plugin/core/build.gradle
breskeby added a commit to breskeby/elasticsearch that referenced this pull request Oct 9, 2025
This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task

(cherry picked from commit f74406d)

# Conflicts:
#	modules/repository-s3/build.gradle
#	plugins/discovery-ec2/build.gradle
#	x-pack/plugin/core/build.gradle
breskeby added a commit to breskeby/elasticsearch that referenced this pull request Oct 9, 2025
This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task

(cherry picked from commit f74406d)

# Conflicts:
#	build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/util/DependenciesUtils.java
#	modules/repository-s3/build.gradle
#	x-pack/plugin/core/build.gradle
#	x-pack/plugin/identity-provider/build.gradle
breskeby added a commit to breskeby/elasticsearch that referenced this pull request Oct 9, 2025
This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task

(cherry picked from commit f74406d)

# Conflicts:
#	build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/util/DependenciesUtils.java
#	modules/repository-s3/build.gradle
#	plugins/discovery-ec2/build.gradle
#	x-pack/plugin/core/build.gradle
#	x-pack/plugin/identity-provider/build.gradle
@breskeby
Copy link
Contributor Author

breskeby commented Oct 9, 2025

💚 All backports created successfully

Status Branch Result
9.2
9.1
9.0
8.19
8.18

Questions ?

Please refer to the Backport tool documentation

elasticsearchmachine pushed a commit that referenced this pull request Oct 9, 2025
This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task

(cherry picked from commit f74406d)
breskeby added a commit that referenced this pull request Oct 10, 2025
* Fix dependency reporting (#136209)

This has been broken since 9.0.3. likely due to some swallowed api change in
Gradle. This fixes and adds test coverage to dependency reporting used in DRA
artifacts building

Fix interdependency to Licenses task

(cherry picked from commit f74406d)

# Conflicts:
#	build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/util/DependenciesUtils.java
#	modules/repository-s3/build.gradle
#	x-pack/plugin/core/build.gradle
#	x-pack/plugin/identity-provider/build.gradle

* [CI] Auto commit changes from spotless

---------

Co-authored-by: elasticsearchmachine <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Automatically create backport pull requests when merged auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) backport pending :Delivery/Build Build or test infrastructure >non-issue Team:Delivery Meta label for Delivery team v8.18.9 v8.19.6 v9.0.9 v9.1.6 v9.2.1 v9.3.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants