启动托管服务器WebLogic 12.2.1.4时尝试同步群集JNDI树时出错



我正在将一个应用程序从WebLogic 12.1.3更新到12.2.1.4。我们的web应用程序位于具有2个节点的集群上。当我们启动2个托管服务器时,无论最后一个完成,都会引发以下异常:

<Notice> <Cluster> <BEA-000138> <Listening for announcements from cluster WEBCluster on 239.255.0.102:10034.>
<Notice> <Cluster> <BEA-000133> <Waiting to synchronize with other running members of WEBCluster.>
<Notice> <Log Management> <BEA-170027> <The server has successfully established a connection with the Domain level Diagnostic Service.>
<Notice> <Cluster> <BEA-000142> <Trying to download cluster JNDI tree from server web-dev01.>
<Error> <Cluster> <BEA-000140> <Failed to deserialize statedump from server web-dev01 with
weblogic.application.ClassLoaderNotFoundException: com.app.ejb.SummaryRemote is not found due to missing GenericClassLoader.annotation:app-ejb@.
weblogic.application.ClassLoaderNotFoundException: com.app.ejb.SummaryRemote is not found due to missing GenericClassLoader.annotation:app-ejb@
at weblogic.application.internal.AppClassLoaderManagerImpl.loadApplicationClass(AppClassLoaderManagerImpl.java:229)
at weblogic.common.internal.ProxyClassResolver.resolveProxyClass(ProxyClassResolver.java:77)
at weblogic.common.internal.WLObjectInputStream.resolveProxyClass(WLObjectInputStream.java:88)
at java.io.ObjectInputStream.readProxyDesc(ObjectInputStream.java:1854)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1802)
Truncated. see log file for complete stacktrace

首先完成的服务器显示以下没有问题:

<Notice> <Log Management> <BEA-170027> <The server has successfully established a connection with the Domain level Diagnostic Service.>
<Notice> <Cluster> <BEA-000138> <Listening for announcements from cluster WEBCluster on 123.123.0.102:10034.>
<Notice> <Cluster> <BEA-000133> <Waiting to synchronize with other running members of WEBCluster.>
<Notice> <WebLogicServer> <BEA-000365> <Server state changed to ADMIN.>
<Notice> <WebLogicServer> <BEA-000365> <Server state changed to RESUMING.>
<Notice> <Cluster> <BEA-000162> <Starting "async" replication service with remote cluster address "null">
<Notice> <WebLogicServer> <BEA-000330> <Started the WebLogic Server Managed Server "web-dev01" for domain "domain" running in production mode.>

Summary.java

package com.app.ejb;
@Stateless(mappedName = "Summary")
public class Summary implements SummaryRemote {
@Inject
private SummaryLocal summaryLocalBean;

SummaryRemote.java

package com.app.ejb;
@Remote
public interface SummaryRemote {

查找

private void getSummaryFacade() throws NamingException {
Context context = new InitialContext();
summaryRemote = (SummaryRemote) context
.lookup("Summary#com.app.ejb.SummaryRemote");
}

为什么它在第一个节点之后启动的集群的节点上抛出ClassLoaderNotFoundException?顺便说一句,我没有为我的项目设置weblogic-ejb-jar.xml或ejb-jar.xml。

查看weblogic控制台中的JNDI树,当我只有一台服务器时,我会看到相同的类加载器未找到异常。我认为,当我启动服务器2时,它正试图从服务器1复制/下载JNDI树,但由于出现错误而无法复制/下载。请参阅JNDI树异常的图像链接

对我来说有效的两个解决方案,做任何一个都消除了异常:

  1. 在WebLogic管理控制台中将群集消息传递模式从多播更改为单播

导航到"环境"->"群集"->"配置"选项卡->"消息传递"选项卡->消息传递模式:多播,您需要按Lock&编辑并从多播更改为单播,然后保存并释放锁定。

  1. 更新weblogic-ejb-jar.xml以使bean不可集群。

    <wls:weblogic-enterprise-bean>
    <wls:ejb-name>Summary</wls:ejb-name>
    <wls:stateless-session-descriptor>
    <wls:stateless-clustering>
    <wls:home-is-clusterable>false</wls:home-is-clusterable>
    <wls:stateless-bean-is-clusterable>false</wls:stateless-bean-is-clusterable>
    </wls:stateless-clustering>
    </wls:stateless-session-descriptor>
    

这可能会导致weblogic中的30295025出现错误。也有类似的问题,在应用了补丁30295025之后,问题就消失了。

文件ID 2689913.1

最新更新