咨询获取MapStruct 1.3预发布版及SNAPSHOT版的Maven仓库
Absolutely! Let's cover both your questions about MapStruct 1.3 repositories clearly:
MapStruct publishes pre-release builds (like release candidates or betas) to the Sonatype OSSRH Staging Repository. To pull these into your Maven project, add the following repository configuration to your pom.xml or settings.xml:
<repository> <id>sonatype-staging</id> <url>https://oss.sonatype.org/content/repositories/staging</url> <releases> <enabled>true</enabled> </releases> <snapshots> <enabled>false</enabled> </snapshots> </repository>
Yes, there’s a dedicated repository for SNAPSHOT builds of MapStruct 1.3, and these builds do include the constructor injection feature you’re interested in — it’s one of the key planned additions for the 1.3 release. Add this repository to your Maven setup to access them:
<repository> <id>sonatype-snapshots</id> <url>https://oss.sonatype.org/content/repositories/snapshots</url> <releases> <enabled>false</enabled> </releases> <snapshots> <enabled>true</enabled> </snapshots> </repository>
A quick heads-up: SNAPSHOT builds are unstable and can change at any time, so they’re best suited for testing, early evaluation, or contributing to MapStruct itself — not for production code.
内容的提问来源于stack exchange,提问作者saw303

