Skip to content

[MRESOLVER-236] Make it possible to resolve .asc on a 'fail' <checksumPolicy/> respository. #1404

@jira-importer

Description

@jira-importer

Rod Widdowson opened MRESOLVER-236 and commented

(I'm guessing the resolver version - maven version is 3.8.4).

We accidently made one of our repositories <checksumPolicy>fail</checksumPolicy> some time ago and over the weekend an plugin we run started failing.

After some digging I discovered that the problem was when the code was programmatically trying to resolve a jar.asc file. Eventually the code ended up in

org.eclipse.aether.internal.impl.Maven2RepositoryLayoutFactory line 196

        public List<Checksum> getChecksums {
            if ( isSignature( artifact.getExtension() ) )
            {
                return Collections.emptyList();
            }

This means that when the resolution hit the correct repository it (silently) failed the checksum check and moved on to the next one, eventually falling off the end of the list and failing to resolve.

Our work around is to set the <checksumPolicy> to warn (which is what it used to be).

'It would be nice if'

  • The failure was slightly less quiet
  • If it was possible - programmatically or by configuration - to resolve signatures from checksuming repositories.

I have not dived very deeply into the code - just enough to diagnose why our CI was exploding so spectacularly so I may have missed some trick in which case I apologise for asking for existing function


Affects: 1.7.3

Issue Links:

  • MRESOLVER-241 Resolver checksum calculation should be driven by layout
    ("is caused by")
  • MRESOLVER-242 When no remote checksums provided by layout, transfer inevitably fails/warns
    ("is caused by")

Remote Links:

0 votes, 6 watchers

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestpriority:minorMinor loss of function, or other problem where easy workaround is present

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions