Update getting-started.adoc
docs: add Maven mirror config note for Spring AI snapshots Add documentation about Maven mirror configuration when using Spring AI snapshots, including examples of correct mirrorOf settings to allow access to Spring repositories. Signed-off-by: shishuiwuhen2009 <90782280+shishuiwuhen2009@users.noreply.github.com>
This commit is contained in:
committed by
Ilayaperumal Gopinathan
parent
9e9980707a
commit
f759883c6c
@@ -70,13 +70,29 @@ repositories {
|
||||
}
|
||||
}
|
||||
----
|
||||
**NOTE:** If you're using Maven mirror settings (typically in `settings.xml`), ensure your `<mirrorOf>` configuration excludes Spring repositories:
|
||||
|
||||
**NOTE:** When using Maven with Spring AI snapshots, pay attention to your Maven mirror configuration. If you have configured a mirror in your `settings.xml` like this:
|
||||
|
||||
```xml
|
||||
<mirror>
|
||||
<mirrorOf>*,!spring-snapshots,!central-portal-snapshots</mirrorOf>
|
||||
<!-- other mirror configurations -->
|
||||
<id>my-mirror</id>
|
||||
<mirrorOf>*</mirrorOf>
|
||||
<url>https://my-company-repository.com/maven</url>
|
||||
</mirror>
|
||||
```
|
||||
|
||||
The wildcard `*` will redirect all repository requests to your mirror, preventing access to Spring snapshot repositories. To fix this, modify the `mirrorOf` configuration to exclude Spring repositories:
|
||||
|
||||
```xml
|
||||
<mirror>
|
||||
<id>my-mirror</id>
|
||||
<mirrorOf>*,!spring-snapshots,!central-portal-snapshots</mirrorOf>
|
||||
<url>https://my-company-repository.com/maven</url>
|
||||
</mirror>
|
||||
```
|
||||
|
||||
This configuration allows Maven to access Spring snapshot repositories directly while still using your mirror for other dependencies.
|
||||
|
||||
======
|
||||
|
||||
[[dependency-management]]
|
||||
|
||||
Reference in New Issue
Block a user