You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Hudson (Jira)" <ji...@apache.org> on 2021/06/08 23:05:00 UTC

[jira] [Commented] (MINDEXER-127) Maven repository indexing error: java.nio.channels.OverlappingFileLockException

    [ https://issues.apache.org/jira/browse/MINDEXER-127?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17359647#comment-17359647 ] 

Hudson commented on MINDEXER-127:
---------------------------------

Build succeeded in Jenkins: Maven » Maven TLP » maven-indexer » master #50

See https://ci-builds.apache.org/job/Maven/job/maven-box/job/maven-indexer/job/master/50/

> Maven repository indexing error: java.nio.channels.OverlappingFileLockException
> -------------------------------------------------------------------------------
>
>                 Key: MINDEXER-127
>                 URL: https://issues.apache.org/jira/browse/MINDEXER-127
>             Project: Maven Indexer
>          Issue Type: Bug
>    Affects Versions: 6.0.0
>            Reporter: Victor Rubezhny
>            Assignee: Sylwester Lachiewicz
>            Priority: Major
>             Fix For: 6.0.1
>
>
> The `openAndWarmup()` method is invoked twice from `purge()` method of `org.apache.maven.index.context.DefaultIndexingContext` which results into `OverlappingFileLockException` during the index re-indexing, because the `openAndWarmup()` method call creates a `FileLock` for an index and the second call tries to create and add the second `FileLock` for the same index which is erroneous:
> ```
> java.nio.channels.OverlappingFileLockException
> at java.base/sun.nio.ch.FileLockTable.checkList(FileLockTable.java:229)
> at java.base/sun.nio.ch.FileLockTable.add(FileLockTable.java:123)
> at java.base/sun.nio.ch.FileChannelImpl.tryLock(FileChannelImpl.java:1154)
> at java.base/java.nio.channels.FileChannel.tryLock(FileChannel.java:1165)
> at org.apache.maven.index.context.DefaultIndexingContext.unlockForcibly(DefaultIndexingContext.java:927)
> at org.apache.maven.index.context.DefaultIndexingContext.prepareIndex(DefaultIndexingContext.java:244)
> at org.apache.maven.index.context.DefaultIndexingContext.purge(DefaultIndexingContext.java:612)
> at org.eclipse.m2e.core.internal.index.nexus.NexusIndexManager.purgeCurrentIndex(NexusIndexManager.java:529)
> at org.eclipse.m2e.core.internal.index.nexus.NexusIndexManager.reindexWorkspace(NexusIndexManager.java:561)
> at org.eclipse.m2e.core.internal.index.nexus.NexusIndexManager.updateIndex(NexusIndexManager.java:1072)
> at org.eclipse.m2e.core.internal.index.nexus.NexusIndex.updateIndex(NexusIndex.java:147)
> at org.eclipse.m2e.core.ui.internal.preferences.MavenSettingsPreferencePage$2.runInWorkspace(MavenSettingsPreferencePage.java:263)
> at org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java:42)
> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
> ```
> The referencing issue is reported at: https://github.com/eclipse-m2e/m2e-core/issues/169



--
This message was sent by Atlassian Jira
(v8.3.4#803005)