0

我希望在我的 Spring Boot 应用程序中使用 Azure SDK。

这是我的 POM 文件中的 repo URL:http://maven.apache.org/maven2

我没有将 Azure 依赖项添加到文件中。我找到了 BOM 文件:https ://repo.maven.apache.org/maven2/com/azure/azure-sdk-bom/

在我的情况下它不起作用。

更准确地说,存储依赖项不起作用(找不到) BOM 依赖项有效,但我无法在其中下载任何依赖项。

下面是我的 pom 文件的预览。

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.test</groupId>
    <artifactId>tesrt</artifactId>
    <version>1.0.0</version>
    <packaging>jar</packaging>

    <name>tesrt</name>
    <url>http://maven.apache.org</url>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <jbcrypt.version>0.4</jbcrypt.version>
        <java.version>1.8</java.version>
    </properties>

    <profiles>
        <profile>
            <id>dev</id>
            <properties>
                <activatedProperties>dev</activatedProperties>
            </properties>
        </profile>
        <profile>
            <id>prod</id>
            <properties>
                <activatedProperties>prod</activatedProperties>
            </properties>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
        </profile>
    </profiles>

    <parent>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-parent</artifactId>
        <version>2.2.4.RELEASE</version>
    </parent>

    <dependencies>

        <!-- AZURE SDK-->

        <dependency>
            <groupId>com.azure</groupId>
            <artifactId>azure-storage-queue</artifactId>
            <version>12.3.0</version>
        </dependency>

        <dependency>
            <groupId>com.azure</groupId>
            <artifactId>azure-sdk-bom</artifactId>
            <version>1.0.4</version>
            <type>pom</type>
            <scope>import</scope>
        </dependency>


        
        
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
            <version>2.2.4.RELEASE</version>
        </dependency>

        <dependency>
            <groupId>com.twilio.sdk</groupId>
            <artifactId>twilio</artifactId>
            <version>7.47.3</version>
        </dependency>

我在 BOM 文件中还有另一个问题:

它说找不到以下内容:

<plugin>
            <groupId>net.jonathangiles.tools</groupId>
            <artifactId>dependencyChecker-maven-plugin</artifactId>
            <version>1.0.6</version> 


      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-antrun-plugin</artifactId>
        <version>1.8</version>
4

0 回答 0