ejb3 javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter,

ejb里面报异常 javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter,

其实就是个很简单的错误,需要引用jboss-client.jar 重点是合适的版本!
网上随便下了个jboss-client4.jar的包,一直报这个异常,其实就是缺少类

从jboss里复制一个新版本出来就好用了

发表评论