Maven pom.xml错误jboss(quickstart文件)

时间:2018-11-13 02:32:24

标签: maven jboss redhat jboss-developer-studio

error

我正在为服务器使用Redhat Developer Studio 12.0和jboss EAP 7.1 我首先尝试快速入门(helloworld)(jboss),所以我会 知道一切是否正常。
我是jboss的新手,对此我真的并不了解。

这是pom.xml

<?xml version="1.0" encoding="UTF-8" standalone="no"?>


<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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
           <groupId>org.jboss.eap.quickstarts</groupId>
           <artifactId>quickstart-parent</artifactId>
           <version>7.1.0.GA</version>
           <relativePath>../pom.xml</relativePath>
       </parent>
    <artifactId>helloworld</artifactId>
    <packaging>war</packaging>
    <name>${qs.name.prefix} helloworld</name>
    <description>Helloworld</description>


    <licenses>
        <license>
            <name>Apache License, Version 2.0</name>
            <distribution>repo</distribution>
            <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
        </license>
    </licenses>


    <dependencies>

        <!-- Import the CDI API, we use provided scope as the API is included in WildFly -->
        <dependency>
            <groupId>javax.enterprise</groupId>
            <artifactId>cdi-api</artifactId>
            <scope>provided</scope>
        </dependency>

        <!-- Import the Common Annotations API (JSR-250), we use provided scope
            as the API is included in WildFly -->
        <dependency>
            <groupId>org.jboss.spec.javax.annotation</groupId>
            <artifactId>jboss-annotations-api_1.2_spec</artifactId>
            <scope>provided</scope>
        </dependency>

        <!-- Import the Servlet API, we use provided scope as the API is included in WildFly -->
        <dependency>
            <groupId>org.jboss.spec.javax.servlet</groupId>
            <artifactId>jboss-servlet-api_3.1_spec</artifactId>
            <scope>provided</scope>
        </dependency>

    </dependencies>

</project>

1 个答案:

答案 0 :(得分:0)

您的pom在上层目录中寻找另一个父pom

private async Task HandleLongRunMessage(TestMessage message, CancellationToken token = default(CancellationToken))
{ 
            // SHORT SYNCHRONOUS TASK - execute as is on the default thread (from thread pool)
            CPU_TASK(message, 50);
            // IO BOUND ASYNCH TASK - used as is
            await Task.Delay(50);
            // BUT WRAP the LONG SYNCHRONOUS TASK inside the Task 
            // which is scheduled on the custom thread pool 
            // (to save threadpool threads)
            await Task.Factory.StartNew(() => {
                CPU_TASK(message, 100000);
            }, token, TaskCreationOptions.DenyChildAttach, _workStealingTaskScheduler);
}

父项目必须存在于<parent> <groupId>org.jboss.eap.quickstarts</groupId> <artifactId>quickstart-parent</artifactId> <version>7.1.0.GA</version> <relativePath>../pom.xml</relativePath> </parent> 使用的路径中

希望有帮助!