Maven 2 & 3

Improve logging when downloading snapshots in offline mode

Details

  • Type: Improvement Improvement
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: 2.0.5
  • Fix Version/s: 2.0.9
  • Labels:
    None
  • Complexity:
    Intermediate
  • Number of attachments :
    0

Description

Even though the network is not touched we get logging output like this:

-->8--

[INFO] snapshot org.codehaus.plexus:plexus-appserver-maven-plugin:2.0-alpha-8-SNAPSHOT: checking for updates from apache.snapshots
[DEBUG] System is offline. Cannot resolve metadata:

Repository Metadata
--------------------------
GroupId: org.codehaus.plexus
ArtifactId: plexus-appserver-maven-plugin
Metadata Type: org.apache.maven.artifact.repository.metadata.SnapshotArtifactRepositoryMetadata

-->8--

Activity

Hide
Mauro Talevi added a comment -

You mean to not log this information when in offline mode?

Simplest thing would be to just allow metadata resolving when online and ignore when not - but throw no RepositoryMetadataResolutionException, both in DefaultRepositoryMetadataManager#resolveAlways() and in
SnapshotTransformation#resolveLatestSnapshotBuildNumber().

Was this the intended result?

Show
Mauro Talevi added a comment - You mean to not log this information when in offline mode? Simplest thing would be to just allow metadata resolving when online and ignore when not - but throw no RepositoryMetadataResolutionException, both in DefaultRepositoryMetadataManager#resolveAlways() and in SnapshotTransformation#resolveLatestSnapshotBuildNumber(). Was this the intended result?
Hide
Brian Fox added a comment -

bumping to the next version

Show
Brian Fox added a comment - bumping to the next version
Hide
Brian Fox added a comment -

Everything seems ok with 2.0.9-SNAPSHOT in offline mode.

Show
Brian Fox added a comment - Everything seems ok with 2.0.9-SNAPSHOT in offline mode.
Hide
Brett Porter added a comment -

actually I fixed this as part of my recent changes to the metadata handling

Show
Brett Porter added a comment - actually I fixed this as part of my recent changes to the metadata handling

People

Vote (2)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: