The implementation currently switches on the redirection when the daemon actually starts reading the System.in stream using InputStream.read() or InputStream.available().
The local repo and maven settings are both used while resolving core extensions,
which happens during daemon startup. Thus these two also need to be discriminating
properties, as the core extensions themselves are discriminating.
* Fixes module id coloring on Maven transfer.
The module id coloring was not consistent during transfer
and it caused "vibrating" effect.
* PR comments
* Improve reproducibility of builds by using digest on docker images
* Inline the manifest Multi-Release entry
* Remove unused files
* Switch the groupId to org.apache.maven.daemon and use maven parent pom
* Fix distribution
* Fix ITs
* Fix native build for windows
* Set default max heap size to null
Let the JVM decide the max heap size instead of using hardcoded defaults
to match the behaviour of vanilla Maven.
* Add ITs for verifying max heap behaviour
- By default no max heap should be set
- If configured via jvm.config then max heap should be set but not mvnd.maxHeapSize
- If configured via mvnd.maxHeapSize then max heap should be set
* Remove defaults memory options
* Add missing test project
* Fix too small heap size
* Fix tests
Co-authored-by: Ashhar Hasan <hashhar_dev@outlook.com>
* Update mvnd to include Maven Resolver 1.7
As mvnd itself is Java8 lang level, it is completely
okay to up resolver to 1.7 (that is java8 as well).
The only reason why Maven 3.8.x CANNOT use resolver
1.7 is that it is still Java7 level.
* Move missing piece to SPI
* Add global exclusions
* Example of mvnd using file locking (of resolver)
* Drop irrelevant
* Upgrade to released 1.7.3
Co-authored-by: Guillaume Nodet <gnodet@gmail.com>
* Provide a local (semaphore based) sync context and use it as the default
* Use a ReentrantLock
* Update daemon/src/main/java/org/mvndaemon/mvnd/sync/MvndSyncContextFactory.java
Co-authored-by: Peter Palaga <ppalaga@redhat.com>
* Improve lock acquisition
Co-authored-by: Peter Palaga <ppalaga@redhat.com>
Fix a possible write a long string in case where the string length is <= 1024 but the encoded size if > 1024.
Truncate long strings and warn instead of throwing an exception which could lead to an invalid registry.
Since the registry data is invalid, the content is emptied to guarantee the next registry will work correct.
This fix is based on #435 provided by @lanmaoxinqing, many thanks !