Tag: websphere 8

将应用程序从websphere 7.0迁移到websphere 8.5.5时遇到问题

该应用程序是在Struts2中开发的,在Websphere 7.0中运行良好。 现在我在Websphere 8.5.5中部署。 它提供登录页面,我可以登录到应用程序,但点击任何菜单,它给出以下例外。 Jars used are – aopalliance-1.0.jar, axis.jar, c3p0-0.9.1.1.jar, com.springsource.javax.transaction-1.1.0.jar, commons-beanutils-1.8.3.jar, commons-beanutils-bean-collections-1.8.3.jar, commons-beanutils-core-1.8.3.jar, commons-collections-3.2.1.jar, commons-io-1.3.2.jar, commons-lang-2.6.jar, commons-logging-1.1.1.jar, commons-logging-adapters-1.1.1.jar, commons-logging-api-1.1.1.jar, commons-logging-tests.jar, commons-logging.jar, datamodel-1.0.jar, displaytag-1.2.jar, dsn.jar, freemarker-2.3.13.jar, jsp-api.jar, jstl-1.2.jar, jstl-standard.jar, log4j-1.2.16.jar, ognl-2.7.3.jar, ojdbc6.jar, poi-3.8-20120326.jar, servlet-api.jar, spring-2.5.6.jar, spring-beans-2.5.6.jar, spring-context-2.5.6.jar, spring-core-2.5.6.jar, struts2-convention-plugin-2.1.6.jar, struts2-core-2.1.6.jar, struts2-dojo-plugin-2.1.6.jar, struts2-jquery-plugin-1.4.jar, struts2-spring-plugin-2.1.8.jar, struts2-tiles-plugin-2.1.6.jar, tiles-api-2.1.2.jar, tiles-compat-2.1.2.jar, tiles-core-2.1.2.jar, tiles-jsp-2.1.2.jar, tiles-portlet-2.1.2.jar, tiles-servlet-2.1.2.jar [2/28/16 12:56:36:880 AST] […]

WAS 8中的EL等效于?

文档说支持参数,但示例使用hl和# ,我不知道在哪里使用c:和$而不是来自docs的$: 我所知道的所有关于EL中的$ vs#都与rvalue和lvalue有关,我需要进一步解释何时使用#style。 我正在寻找typ $ …的EL表达式如何获取参数以及如何使用参数调用非getter非setter,例如从请求上下文中的bean中获取常量静态字符串。 与$相比,#做什么? 如果我想使用$,如何在EL中使用参数? 我想要迁移到EL的scriptlet类似于我想在EL中执行的和 。

在websphere共享库中使用CDI

我们使用websphere管理控制台中定义的共享库在多个应用程序之间共享类。 我想知道是否可以在这些类中使用CDI(上下文和dependency injection)? 如果是这样,我只需要将beans.xml放在共享库中的jar中,还是有进一步的步骤? 注意:我不能放弃使用共享库,因为这将是太多的重构工作。

Spring + Websphere 8.5:无法查找JNDI名称

有一个运行XA Datasource的Websphere AS 8.5。 还有一个Spring应用程序必须在此环境中工作并连接到数据源。 应用程序上下文由servlet加载,应用程序使用RmiExporters提供对某些服务的RMI访问(在单独的线程中共享),所有DAO的方法都用@Transactional标记。 如果我尝试从主线程向数据库写一些东西(例如在任何类的初始化期间),它可以正常工作。 但是如果我尝试通过RMI调用来编写(或使用HQL SELECT-query读取),我会看到一个exception: org.hibernate.service.jndi.JndiException: Unable to lookup JNDI name [java:comp/websphere/ExtendedJTATransaction] at org.hibernate.service.jndi.internal.JndiServiceImpl.locate(JndiServiceImpl.java:68) at org.hibernate.service.jta.platform.internal.WebSphereExtendedJtaPlatform$TransactionManagerAdapter$TransactionAdapter.(WebSphereExtendedJtaPlatform.java:156) at org.hibernate.service.jta.platform.internal.WebSphereExtendedJtaPlatform$TransactionManagerAdapter$TransactionAdapter.(WebSphereExtendedJtaPlatform.java:152) at org.hibernate.service.jta.platform.internal.WebSphereExtendedJtaPlatform$TransactionManagerAdapter.getTransaction(WebSphereExtendedJtaPlatform.java:124) at org.hibernate.service.jta.platform.internal.WebSphereExtendedJtaPlatform$TransactionManagerAdapter.getStatus(WebSphereExtendedJtaPlatform.java:119) at org.hibernate.engine.transaction.internal.jta.JtaStatusHelper.getStatus(JtaStatusHelper.java:73) at org.hibernate.engine.transaction.internal.jta.JtaStatusHelper.isActive(JtaStatusHelper.java:115) at org.hibernate.service.jta.platform.internal.TransactionManagerBasedSynchronizationStrategy.canRegisterSynchronization(TransactionManagerBasedSynchronizationStrategy.java:56) at org.hibernate.service.jta.platform.internal.AbstractJtaPlatform.canRegisterSynchronization(AbstractJtaPlatform.java:148) at org.hibernate.engine.transaction.internal.TransactionCoordinatorImpl.attemptToRegisterJtaSync(TransactionCoordinatorImpl.java:240) at org.hibernate.engine.transaction.internal.TransactionCoordinatorImpl.pulse(TransactionCoordinatorImpl.java:268) at org.hibernate.ejb.AbstractEntityManagerImpl.joinTransaction(AbstractEntityManagerImpl.java:1202) at org.hibernate.ejb.AbstractEntityManagerImpl.postInit(AbstractEntityManagerImpl.java:178) at org.hibernate.ejb.EntityManagerImpl.(EntityManagerImpl.java:89) at org.hibernate.ejb.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:179) at org.hibernate.ejb.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:174) at com.ibm.ws.jpa.management.JPAEMFactory.createEntityManager(JPAEMFactory.java:297) at org.springframework.orm.jpa.EntityManagerFactoryUtils.doGetTransactionalEntityManager(EntityManagerFactoryUtils.java:202) at org.springframework.orm.jpa.SharedEntityManagerCreator$SharedEntityManagerInvocationHandler.invoke(SharedEntityManagerCreator.java:211) at […]

部署Spring Boot 1.3.2 IBM WAS 8.5

我在使用完整配置文件在IBM Websphere 8.5.5.8上部署简单的spring boot Web时遇到了问题 默认情况下,WAS使用servlet 3.0和java 1.7。 应用程序没有太大作用,只显示一个“Hi – [current-date]”页面。 部署war文件时,我们在服务器日志输出中看到以下内容: [2/3/16 13:30:44:857 AST] 00000078 AdminHelper A ADMN1008I: An attempt is made to start the simpledemo_war application. (User ID = defaultWIMFileBasedRealm/wps_admin) [2/3/16 13:30:44:871 AST] 00000078 CompositionUn A WSVR0190I: Starting composition unit WebSphere:cuname=simpledemo_war in BLA WebSphere:blaname=simpledemo_war. [2/3/16 13:30:44:958 AST] 00000078 ApplicationMg A WSVR0200I: Starting application: […]

无法在websphere 8.5.5中启动我的应用程序

当我在websphere 8.5.5中启动应用程序时出现错误,应用程序无法启动,我搜索了日志并得到了这个堆栈跟踪。 你们有什么想法吗? [8/21/14 17:58:57:437 EEST] 00000001 ContainerHelp E WSVR0501E: Error creating component com.ibm.ws.runtime.component.CompositionUnitMgrImpl@a0ccb3b2 com.ibm.ws.exception.RuntimeWarning: com.ibm.ws.webcontainer.exception.WebAppNotLoadedException: Failed to load webapp: Failed to load webapp: java.lang.LinkageError: javax/servlet/jsp/JspApplicationContext.addELResolver(Ljavax/el/ELResolver&#59;)V at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:432) at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:718) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1175) at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1370) at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:639) at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:968) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:774) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2182) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$CUInitializer.run(CompositionUnitMgrImpl.java:994) at com.ibm.wsspi.runtime.component.WsComponentImpl$_AsynchInitializer.run(WsComponentImpl.java:502) at […]

启用安全性后,从Eclipse启动Websphere会挂起

我有一个Websphere Application Server 8.0.0.6,它作为RAD的一部分安装。 我需要从Eclipse Java EE Kepler或Luna运行服务器。 禁用管理安全性时没有问题。 但是,一旦启用安全性,服务器将无法完全启动,或者Ecplise无法检测到它。 进度条停止在23%。 记录的最后一条消息是“服务器server1为电子商务开放”。 然而,状态仍然是“开始”。 过了一会儿,我得到一个错误,抱怨服务器没有在300秒内启动。 然后它尝试停止服务器,并且无限期地“停止”。 服务器启动,Eclipse似乎无法看到它。 我无法从Eclipse中访问管理控制台(虽然我可以使用浏览器),我无法发布或调试应用程序,我无法从Eclipse停止服务器。 开普勒和卢娜都会发生这种情况。 服务器在RAD中启动正常,或者在启动脚本启动时启动。 我已经检查了从RAD挂起的“服务器服务器1打开电子商务”的启动websphere服务器 。 还有一个类似的问题: RAD中的Websphere在启动时挂起 ,但没有解决方案。 更新:问题是在Websphere启动之后Ecipse和Websphere之间的通信(正如wFateem也指出的那样)。 Eclipse对Websphere进行SOAP调用以检查状态。 如果在WAS中禁用了管理安全性,它将接受纯HTTP中的SOAP调用。 启用安全性后,仅允许HTTPS。 我使用Eclipse内置的TCP-Monitor检查了Eclipse和WAS之间的通信。 使用禁用的安全性,我可以看到成功的SOAP调用。 启用安全性后,我希望只看到二进制SSL数据。 但是,Eclipse仍在尝试使用HTTP,当然没有任何成功。 Eclipse有一个WAS服务器设置,用于指示服务器是安全的,以及用于调用的用户和密码。 它甚至有一个与SSL通信有关的标志(“在SSL握手期间自动信任服务器证书”)。 但是,由于某种原因,它还没有使用SSL。 在我的旧开发机器上,我没有遇到任何问题,几天前它被我当前的机器所取代。 因此,当前状态是:Eclipse在与WAS通信时不使用SSL,即使它知道服务器是安全的。 现在的问题是:Eclipse没有使用SSL与安全服务器通信,我做错了什么?

将属性文件放在IBM websphere 8.5中的最佳位置?

在我们现有的应用程序属性文件嵌入在jar文件中,我们决定将属性文件移到耳朵外(应用程序),在IBM websphere 8.5中放置属性文件的最佳位置是什么? 这样我就可以使用WAS环境变量检索路径,并且文件应该可用于集群中的所有节点。

JAXWS Soap Handler大型MTOM附件

IBM SOAP 7和8中的JAXWS实现在肥皂处理程序和大型MTOM附件方面似乎存在一些问题。 当在SOAPMessageContext对象上调用getMessage()时,似乎将整个消息(包括所有附件二进制内容)读入内存。 这很容易导致JVM耗尽可用内存。 @Override public boolean handleMessage(SOAPMessageContext context) { SOAPMessage soapMsg = context.getMessage(); … } 在上面的代码片段中,如果传入的请求附件大于JVM中可用的可用内存量,则context.getMessage()可能导致内存不足exception。 如何在不触发此不良function的情况下访问SoapHeader元素? 我看到SOAPMessageContext类有一个getHeaders(…)方法,但我不确定如何使用它。 我特别不确定要为JAXBContext传递什么。 任何人都可以提供一个例子或解释如何使用这种方法吗? 这是另一个相关的stackoverflow文章: 带有大消息的JAX-WS SoapHandler:OutOfMemoryError

找不到资源引用绑定

目前,我尝试将Web服务系统从Websphere 6升级到Websphere 8.5。 但是我遇到了这样的问题 CWNEN0044E:找不到为组件定义的/ wsContext资源引用的资源引用绑定。 在源代码中,该部分仅包含 @Resource WebServiceContext wsContext; 如果我将类装入器策略从父级切换到父级,则此错误将消失。 但是,你知道吗?无论如何要避免“父母最后”这个错误?