Skip to content

Add explicit ignorePublishedComponents configuration to published modules#179

Merged
RomanIakovlev merged 2 commits intomasterfrom
copilot/ignore-published-components-release
Nov 7, 2025
Merged

Add explicit ignorePublishedComponents configuration to published modules#179
RomanIakovlev merged 2 commits intomasterfrom
copilot/ignore-published-components-release

Conversation

Copy link
Contributor

Copilot AI commented Nov 7, 2025

Explicitly configure ignorePublishedComponents=true on the central-publishing-maven-plugin for all modules published to Maven Central.

Changes

  • core/pom.xml: Add explicit plugin configuration with ignorePublishedComponents=true
  • geojson-proto/pom.xml: Add explicit plugin configuration with ignorePublishedComponents=true

The parent POM already sets this property, but explicit module-level configuration ensures the setting is independent of inheritance and clearly documented where it matters.

<plugin>
    <groupId>org.sonatype.central</groupId>
    <artifactId>central-publishing-maven-plugin</artifactId>
    <configuration>
        <ignorePublishedComponents>true</ignorePublishedComponents>
    </configuration>
</plugin>

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • repository.sonatype.org
    • Triggering command: /usr/lib/jvm/temurin-17-jdk-amd64/bin/java --enable-native-access=ALL-UNNAMED -classpath /usr/share/apache-maven-3.9.11/boot/plexus-classworlds-2.9.0.jar -Dclassworlds.conf=/usr/share/apache-maven-3.9.11/bin/m2.conf -Dmaven.home=/usr/share/apache-maven-3.9.11 -Dlibrary.jansi.path=/usr/share/apache-maven-3.9.11/lib/jansi-native -Dmaven.multiModuleProjectDirectory=/home/REDACTED/work/timeshape/timeshape org.codehaus.plexus.classworlds.launcher.Launcher help:describe -Dplugin=org.sonatype.central:central-publishing-maven-plugin:0.8.0 -Ddetail (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Original prompt

I want you to make change that ignores already published components during release to Maven Central. You should set the ignorePublishedComponents property to true on all components that are published.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: RomanIakovlev <2363458+RomanIakovlev@users.noreply.github.com>
Copilot AI changed the title [WIP] Set ignorePublishedComponents to true for release Add explicit ignorePublishedComponents configuration to published modules Nov 7, 2025
Copilot AI requested a review from RomanIakovlev November 7, 2025 13:43
@RomanIakovlev
Copy link
Owner

@copilot Last time I've tried to publish the project, I've got the following errors:

Deployment 452cd21a-215c-4196-9b88-4b25578991be failed
pkg:maven/net.iakovlev/timeshape@2025b.28:
 - Component with package url: 'pkg:maven/net.iakovlev/timeshape@2025b.28' already exists

pkg:maven/net.iakovlev/geojson-proto@1.1.6:
 - Component with package url: 'pkg:maven/net.iakovlev/geojson-proto@1.1.6' already exists

pkg:maven/net.iakovlev/timeshape-parent@2025b.28?type=pom:
 - Component with package url: 'pkg:maven/net.iakovlev/timeshape-parent@2025b.28?type=pom' already exists

You have made changes to the first two components, as far as I can tell. What about the third one?

Copy link
Contributor Author

Copilot AI commented Nov 7, 2025

@copilot Last time I've tried to publish the project, I've got the following errors:

Deployment 452cd21a-215c-4196-9b88-4b25578991be failed...

The parent POM (timeshape-parent) already has ignorePublishedComponents=true configured in the central-publishing-maven-plugin at line 128 of pom.xml. This was added in commit 258e509.

All three published components now have the setting:

  • timeshape-parent@2025b.28?type=pom - configured in parent pom.xml (line 128)
  • timeshape@2025b.28 - configured in core/pom.xml (added in 526dd9f)
  • geojson-proto@1.1.6 - configured in geojson-proto/pom.xml (added in 526dd9f)

If the deployment is still failing with "already exists" errors after these changes, there may be an issue with how the plugin applies this setting during the deploy phase. The configuration structure looks correct based on the plugin documentation.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • repository.sonatype.org

If you need me to access, download, or install something from one of these locations, you can either:

@RomanIakovlev RomanIakovlev marked this pull request as ready for review November 7, 2025 13:55
@RomanIakovlev RomanIakovlev merged commit fb3d94e into master Nov 7, 2025
3 checks passed
@RomanIakovlev RomanIakovlev deleted the copilot/ignore-published-components-release branch November 7, 2025 13:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants