0

Jboss 7.1.1と を使用して OAuth 2.0 サーバーをセットアップしていますResteasy 3.0-beta-3私は公式ドキュメントに従い、最終的にDatabaseServerLoginModule.

戦争を耳の中に入れると問題が発生します。アプリケーションを再デプロイすると、次のエラーが表示されます。

13:32:58,336 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-3) MSC00001: Failed to start service jboss.deployment.subunit."JauBM-EAR.ear"."JauBM-WEB.war".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.subunit."JauBM-EAR.ear"."JauBM-WEB.war".INSTALL: Failed to process phase INSTALL of subdeployment "JauBM-WEB.war" of deployment "JauBM-EAR.ear"
    at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:119) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
    at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
    at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0_03]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0_03]
    at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_03]
Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: JBAS018096: Error instantiating container component: org.jboss.resteasy.skeleton.key.as7.OAuthAuthenticationServerValve
    at org.jboss.as.web.deployment.WarDeploymentProcessor.getInstance(WarDeploymentProcessor.java:386)
    at org.jboss.as.web.deployment.WarDeploymentProcessor.processDeployment(WarDeploymentProcessor.java:210)
    at org.jboss.as.web.deployment.WarDeploymentProcessor.deploy(WarDeploymentProcessor.java:114)
    at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:113) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
    ... 5 more
Caused by: java.lang.ClassNotFoundException: org.jboss.resteasy.skeleton.key.as7.OAuthAuthenticationServerValve from [Module "deployment.JauBM-EAR.ear.JauBM-WEB.war:main" from Service Module Loader]
    at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)
    at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)
    at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)
    at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)
    at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)
    at org.jboss.as.web.deployment.WarDeploymentProcessor.getInstance(WarDeploymentProcessor.java:378)
    ... 8 more

私は何か見落としてますか?

4

1 に答える 1

3

問題が何であるかを理解したので、誰かが同じ問題を抱えている場合に備えて、質問に答えることにしました。jboss-deployment-structure.xml解決策は、ファイルを EAR ファイルに移動し、次のように変更することでした。

JauBM-Oauth/WebContent/WEB-INF/jboss-deployment-structure.xml(削除)

<jboss-deployment-structure>
    <deployment>
        <dependencies>
            <module name="org.jboss.resteasy.resteasy-jaxrs" services="import"/>
            <module name="org.jboss.resteasy.resteasy-jackson-provider" services="import"/>
            <module name="org.jboss.resteasy.skeleton-key"/>
        </dependencies>
    </deployment>
</jboss-deployment-structure>

EAR/META-INF/jboss-deployment-structure.xml(作成した)

<?xml version="1.0" encoding="UTF-8"?>
<jboss-deployment-structure>
    <sub-deployment name="JauBM-Oauth.war">
        <dependencies>
            <module name="org.jboss.resteasy.resteasy-jaxrs" services="import"
                export="true" />
            <module name="org.jboss.resteasy.resteasy-jackson-provider"
                services="import" export="true" />
            <module name="org.jboss.resteasy.skeleton-key" export="true" />
        </dependencies>
    </sub-deployment>
</jboss-deployment-structure>
于 2013-02-13T15:35:53.357 に答える