Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-07 Thread via GitHub
cstamas merged PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@maven.ap

Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-07 Thread via GitHub
oehme commented on PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281#issuecomment-2706954506 Added the thread-based test back and did some final cleanups, this should be good to go now. -- This is an automated message from the Apache Git Service. To respond to the message, ple

Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-07 Thread via GitHub
cstamas commented on code in PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281#discussion_r1984672396 ## common/src/main/java/org/mvndaemon/mvnd/common/DaemonRegistry.java: ## @@ -18,15 +18,11 @@ */ package org.mvndaemon.mvnd.common; -import java.io.IOException;

Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-07 Thread via GitHub
cstamas commented on PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281#issuecomment-2705865894 Cool beans! Nice and thanks! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specifi

Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-06 Thread via GitHub
oehme commented on PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281#issuecomment-2705773931 Sorry I had to edit my message above, you probably responded to the first version where I had doubted the memory mapping change. The memory mapping was the second part of the problem aft

Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-06 Thread via GitHub
gnodet commented on PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281#issuecomment-2705728187 I'm not completely at ease with dropping the shared memory mapped file which afaik, will result in a performance loss. The use of this memory mapped file seems really a good use case,

Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-06 Thread via GitHub
oehme commented on PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281#issuecomment-2705073602 Turns out the real issue was in the `tryLock` method, which just silently returned `null` when the file couldn't be locked. Also today I learned that `try-with-resources` will happily ac

Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-06 Thread via GitHub
oehme commented on PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281#issuecomment-2704922967 Those mac/windows failures indicate there's still something wrong - I'll rework the test to use multiple processes instead of only multiple threads. Hopefully that'll uncover the problem

Re: [PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-06 Thread via GitHub
gnodet commented on PR #1281: URL: https://github.com/apache/maven-mvnd/pull/1281#issuecomment-2704784630 Awesome work ! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To

[PR] Make DaemonRegistry concurrency-safe [maven-mvnd]

2025-03-06 Thread via GitHub
oehme opened a new pull request, #1281: URL: https://github.com/apache/maven-mvnd/pull/1281 The previous implementation used a memory-mapped file, which is not guaranteed to reflect changes made by other processes, like expanding the file content. Memory mapping only makes sense for large f