首页 > 解决方案 > 野蝇 2x | 服务器简历

问题描述

我遇到了 Wildfly 23.0.2.Final 意外的自动 EAR 重启(也通过 22.0.1.Final 和 23.0.0.Final 进行了验证)。

基本上,发生的情况是应用程序已启动,但当一切都启动并运行时,我收到一条消息,读取WFLYSRV0212: Resuming server并重新开始部署过程。这似乎也危及 JMS 队列定义(在 EJB 模块中定义为@JMSResourceDestinations)。

在发生这种情况时的日志片段下方(只是有点匿名):

13:16:12,228 INFO  [org.jboss.as.server] (ServerService Thread Pool -- 48) WFLYSRV0010: Deployed "XXXX.ear" (runtime-name : "XXXX.ear")
13:16:12,250 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-5) WFLYJCA0019: Stopped Driver service with driver-name = XXXXX.ear_org.postgresql.Driver_42_2
13:16:12,251 INFO  [org.jboss.as.server] (Controller Boot Thread) WFLYSRV0212: Resuming server
13:16:12,260 INFO  [org.wildfly.extension.undertow] (ServerService Thread Pool -- 9) WFLYUT0022: Unregistered web context: '/api' from server 'default-server'
13:16:12,269 INFO  [io.undertow.servlet] (ServerService Thread Pool -- 9) Closing Spring root WebApplicationContext
13:16:12,303 WARN  [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 25) AMQ222061: Client connection failed, clearing up resources for session 1610e737-d282-11eb-9d4b-0242e77fb65d
13:16:12,309 WARN  [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 25) AMQ222107: Cleared up resources for session 1610e737-d282-11eb-9d4b-0242e77fb65d
13:16:12,313 WARN  [org.apache.activemq.artemis.ra] (default-threads - 1) AMQ152005: Failure in broker activation org.apache.activemq.artemis.ra.inflow.ActiveMQActivationSpec(ra=org.wildfly.extension.messaging.activemq.ActiveMQResourceAdapter@9f1bfbc destination=java:global/XXXX/jms/queue/queue1 destinationType=javax.jms.Queue ack=Auto-acknowledge durable=false clientID=null user=null maxSession=15): ActiveMQUnBlockedException[errorType=UNBLOCKED message=AMQ219016: Connection failure detected. Unblocking a blocking call that will never get a response]
    at org.apache.activemq.artemis@2.16.0//org.apache.activemq.artemis.core.protocol.core.impl.ChannelImpl.sendBlocking(ChannelImpl.java:540)
    at org.apache.activemq.artemis@2.16.0//org.apache.activemq.artemis.core.protocol.core.impl.ChannelImpl.sendBlocking(ChannelImpl.java:434)
    at org.apache.activemq.artemis@2.16.0//org.apache.activemq.artemis.core.protocol.core.impl.ActiveMQClientProtocolManager.createSessionContext(ActiveMQClientProtocolManager.java:300)
    at org.apache.activemq.artemis@2.16.0//org.apache.activemq.artemis.core.protocol.core.impl.ActiveMQClientProtocolManager.createSessionContext(ActiveMQClientProtocolManager.java:249)
    at org.apache.activemq.artemis@2.16.0//org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl.createSessionChannel(ClientSessionFactoryImpl.java:1401)
    at org.apache.activemq.artemis@2.16.0//org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl.createSessionInternal(ClientSessionFactoryImpl.java:705)
    at org.apache.activemq.artemis@2.16.0//org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl.createSession(ClientSessionFactoryImpl.java:316)
    at org.apache.activemq.artemis.ra@2.16.0//org.apache.activemq.artemis.ra.ActiveMQResourceAdapter.createSession(ActiveMQResourceAdapter.java:1602)
    at org.apache.activemq.artemis.ra@2.16.0//org.apache.activemq.artemis.ra.inflow.ActiveMQActivation.setupSession(ActiveMQActivation.java:491)
    at org.apache.activemq.artemis.ra@2.16.0//org.apache.activemq.artemis.ra.inflow.ActiveMQActivation.setup(ActiveMQActivation.java:316)
    at org.apache.activemq.artemis.ra@2.16.0//org.apache.activemq.artemis.ra.inflow.ActiveMQActivation$SetupActivation.run(ActiveMQActivation.java:764)
    at org.wildfly.extension.messaging-activemq//org.wildfly.extension.messaging.activemq.ActiveMQResourceAdapter$WorkWrapper.run(ActiveMQResourceAdapter.java:161)
    at org.jboss.ironjacamar.impl@1.4.27.Final//org.jboss.jca.core.workmanager.WorkWrapper.runWork(WorkWrapper.java:445)
    at org.jboss.as.connector@23.0.2.Final//org.jboss.as.connector.services.workmanager.WildflyWorkWrapper.runWork(WildflyWorkWrapper.java:69)
    at org.jboss.ironjacamar.impl@1.4.27.Final//org.jboss.jca.core.workmanager.WorkWrapper.run(WorkWrapper.java:223)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.SimpleDirectExecutor.execute(SimpleDirectExecutor.java:29)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.QueueExecutor.runTask(QueueExecutor.java:789)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.QueueExecutor.access$100(QueueExecutor.java:44)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.QueueExecutor$Worker.run(QueueExecutor.java:809)
    at java.base/java.lang.Thread.run(Thread.java:829)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.JBossThread.run(JBossThread.java:513)

13:16:12,329 INFO  [org.wildfly.extension.messaging-activemq] (MSC service thread 1-5) WFLYMSGAMQ0006: Unbound messaging object to jndi name java:global/XXXX/jms/queue/queue1

EAR 是使用特定的 Wildfly 原型创建的。Wildfly 实例的配置是standalone-full,因为它是开箱即用的。

谁能帮助我了解发生了什么?


更新:野蝇日志

增加根日志级别并通过它,我发现以下内容:

2021-06-22 18:44:59,357 DEBUG [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) Deployment scan of [/home/xxxx/wildfly-23.0.2.Final/standalone/deployments] found update action [{
    "operation" => "composite",
    "address" => [],
    "steps" => [
        {
            "operation" => "add",
            "address" => [("deployment" => "togather-engine.ear")],
            "content" => [{
                "archive" => false,
                "path" => "deployments/XXXX.ear",
                "relative-to" => "jboss.server.base.dir"
            }],
            "persistent" => false,
            "owner" => [
                ("subsystem" => "deployment-scanner"),
                ("scanner" => "default")
            ]
        },
        {
            "operation" => "deploy",
            "address" => [("deployment" => "XXXX.ear")],
            "owner" => [
                ("subsystem" => "deployment-scanner"),
                ("scanner" => "default")
            ]
        }
    ],
    "operation-headers" => {"rollback-on-runtime-failure" => false}
}]

过了一会儿

2021-06-22 18:45:11,886 DEBUG [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 2) Deployment scan of [/home/xxxxx/wildfly-23.0.2.Final/standalone/deployments] found update action [{
    "operation" => "redeploy",
    "address" => [("deployment" => "XXXX.ear")],
    "owner" => [
        ("subsystem" => "deployment-scanner"),
        ("scanner" => "default")
    ]
}]

看起来它实际上正在经历两次部署。

标签: wildflyear

解决方案


推荐阅读