如何在JBoss中修复java.lang.IllegalStateException&“已注册"? [英] How should I try to fix java.lang.IllegalStateException in JBoss "is already registered"?

查看:83
本文介绍了如何在JBoss中修复java.lang.IllegalStateException&“已注册"?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个Web应用程序.当我尝试通过Netbeans部署它时,JBoss服务器抛出以下错误:

I have a web application. When I try to deploy it via Netbeans, the JBoss server throws the following error:

DEPLOYMENTS IN ERROR:
  Deployment "vfs:///path/to/my/Application.ear" is in error due to the following reason(s): java.lang.IllegalStateException: Container jboss.j2ee:ear=Application.ear,jar=Application-ejb.jar,name=Another,service=EJB3,VMID=583c10bfdbd326ba:71d035f1:132a4c6a8ba:-7ffd + is already registered

    at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:1370) [:2.2.0.GA]
    at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:1316) [:2.2.0.GA]
    at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:968) [:2.2.0.GA]
    at org.jboss.system.server.profileservice.deployers.MainDeployerPlugin.checkComplete(MainDeployerPlugin.java:82) [:6.0.0.Final]
    at org.jboss.profileservice.dependency.ProfileControllerContext$DelegateDeployer.checkComplete(ProfileControllerContext.java:138) [:0.2.2]
    at org.jboss.profileservice.plugins.deploy.actions.DeploymentStartAction.doPrepare(DeploymentStartAction.java:104) [:0.2.2]
    at org.jboss.profileservice.management.actions.AbstractTwoPhaseModificationAction.prepare(AbstractTwoPhaseModificationAction.java:101) [:0.2.2]
    at org.jboss.profileservice.management.ModificationSession.prepare(ModificationSession.java:87) [:0.2.2]
    at org.jboss.profileservice.management.AbstractActionController.internalPerfom(AbstractActionController.java:234) [:0.2.2]
    at org.jboss.profileservice.management.AbstractActionController.performWrite(AbstractActionController.java:213) [:0.2.2]
    at org.jboss.profileservice.management.AbstractActionController.perform(AbstractActionController.java:150) [:0.2.2]
    at org.jboss.profileservice.plugins.deploy.AbstractDeployHandler.startDeployments(AbstractDeployHandler.java:168) [:0.2.2]
    at org.jboss.profileservice.management.upload.remoting.DeployHandlerDelegate.startDeployments(DeployHandlerDelegate.java:74) [:6.0.0.Final]
    at org.jboss.profileservice.management.upload.remoting.DeployHandler.invoke(DeployHandler.java:156) [:6.0.0.Final]
    at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:898) [:6.0.0.Final]
    at org.jboss.remoting.transport.socket.ServerThread.completeInvocation(ServerThread.java:791) [:6.0.0.Final]
    at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:744) [:6.0.0.Final]
    at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:548) [:6.0.0.Final]
    at org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:234) [:6.0.0.Final]

我在Google上搜索时发现了很多结果,因此这种错误似乎经常出现.但是我看到的所有结果都是论坛中的帖子,没有显示如何常规地解决它.

I found many results when I google this, so this kind of error seems to appear quite often. But all results I saw were posts in forums which didn't show how to fix it in a general way.

问题似乎是该应用程序已在JBoss中注册.在哪里可以获得注册的JBoss应用程序的列表?如何注销应用程序(如果有帮助的话).

The problem seems to be that the application is already registered in JBoss. Where can I get a list of registered JBoss applications? How can I de-register an application (if this could help).

尝试解决此类问题的好方法是什么?

What is a good way to try to fix this kind of problem?

推荐答案

您有可能在.jar目录/归档中部署了多个类文件,其中一个是错误放置的.如果您是从unix展开部署的,则可以通过以下命令搜索类文件,以查找上述引发的问题:

There are chances that you may have multiple class files deployed in your .jar directory/archive one of which is places all by mistake. If you have deployed in exploded from on unix you may search the class file by below command for above raised issue as:

find . -name Another -print

在删除不需要的文件并重新启动服务器之后,以上问题应该已经解决/修复/解决了.

there after remove the unrequired file and restart the server and the above problem should have been solved/fixed/resolved.

这篇关于如何在JBoss中修复java.lang.IllegalStateException&“已注册"?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆