"加载应用程序时出现异常",没有堆栈跟踪

Nic*_*ick 8 deployment glassfish nullpointerexception java-ee jboss-weld

我正在将我的应用程序从GlassFish 3.0.1迁移到GlassFish 3.1.1.部署失败,并显示以下错误消息:

SEVERE: Exception while loading the app
SEVERE: Exception while shutting down application container
SEVERE: Exception while shutting down application container : java.lang.NullPointerException
SEVERE: java.lang.RuntimeException: Error occurred during deployment: Exception while shutting down application container : java.lang.NullPointerException. Please see server.log for more details. 
Run Code Online (Sandbox Code Playgroud)

没有堆栈跟踪.我将根日志记录级别设置为FINEST,并在Weld消息之后发生第一条SEVERE消息:

//...
FINE: WELD-000105 Enabled interceptor types for Manager
Enabled alternatives: [] []
Registered contexts: [interface javax.enterprise.context.SessionScoped, interface javax.enterprise.context.RequestScoped, interface javax.inject.Singleton, interface javax.enterprise.context.Dependent, interface javax.enterprise.context.ApplicationScoped, interface javax.enterprise.context.ConversationScoped]
Registered beans: 0
Specialized beans: 0
: []
Run Code Online (Sandbox Code Playgroud)

在这些消息之前(对于几个不同的类):

FINE: PWC4451: File cannot be read /opt/sun/glassfish-3.1.1/glassfish/domains/domain1/applications/QmsWeb/WEB-INF/classes/org/jboss/seam/transaction/SeamTransaction.class
FINE: PWC4451: File cannot be read /opt/sun/glassfish-3.1.1/glassfish/domains/domain1/applications/QmsWeb/WEB-INF/classes/org/jboss/seam/transaction/SeamTransaction.class
FINE: PWC4451: File cannot be read /opt/sun/glassfish-3.1.1/glassfish/domains/domain1/applications/QmsWeb/WEB-INF/classes/net/sf/ehcache/config/TerracottaConfiguration$ValueMode.class
//...
Run Code Online (Sandbox Code Playgroud)

可能导致此错误的原因是什么?这些PWC4451消息是否可以指示某些库未加载?

Nic*_*ick 6

这是由于@ViewScoped bean没有实现Serializable.显然,我们使用的较旧版本的Weld并没有发现钝化范围的bean不是Serializable令人反感,但是这个因为它而无声地失败.哦,希望这能节省一些时间.