• tomee 系列问题


    1. remote client 无法建立连接

    修改system.properties

    # allowed packages to be deserialized, by security we denied all by default, tune tomee.serialization.class.whitelist packages to change it
    tomee.remote.support = true
    #tomee.serialization.class.blacklist = *
    # tomee.serialization.class.whitelist = my.package

    2. class not found

    		<dependency>
    			<groupId>org.apache.openejb</groupId>
    			<artifactId>javaee-api</artifactId>
    			<version>6.0-6</version>
    			<scope>provided</scope>
    		</dependency>
    		<dependency>
    			<groupId>org.apache.activemq</groupId>
    			<artifactId>activemq-ra</artifactId>
    			<version>5.14.0</version>
    			<scope>provided</scope>
    		</dependency>
    		<dependency>
    			<groupId>org.apache.geronimo.components</groupId>
    			<artifactId>geronimo-connector</artifactId>
    			<version>3.1.3</version>
    			<scope>provided</scope>
    		</dependency>

    如下列表(添加到tomee lib):

    activemq-broker-5.14.0.jar
    activemq-client-5.14.0.jar
    activemq-kahadb-store-5.14.0.jar
    activemq-openwire-legacy-5.14.0.jar
    activemq-protobuf-1.1.jar
    activemq-ra-5.14.0.jar
    geronimo-connector-3.1.3.jar
    geronimo-transaction-3.1.3.jar
    hawtbuf-1.11.jar

    3. JNDI lookup for a QueueConnectionFactory return null

    jndi.properties 文件里的属性配置存在问题。

    尤其是 [java.naming.factory.initial] 需要特别注意

    不同的java ee 服务器 ,实现方式不一样,比如 tomee , weblogic , etc.

    当为tomee时,

    应当使用 org.apache.activemq.jndi.ActiveMQInitialContextFactory 的规则进行处理

    具体实现规则见官方链接

    http://activemq.apache.org/jndi-support.html

    4.Transport Connection to: tcp://127.0.0.1:64412 failed

    八月 29, 2016 12:30:30 上午 org.apache.activemq.broker.TransportConnection serviceTransportException
    警告: Transport Connection to: tcp://127.0.0.1:64412 failed: java.net.SocketException: Connection reset

    原因是客户端使用connection 和 session 后没有进行close 操作。

    解决

            if (session != null)session.close();
            if (connection != null)connection.close();

    5.$Proxy66 cannot be cast to org.omg.CORBA.Obejct

     将ejb2.0 配置的 home interface 修改为ejb3.0 的business-remote

    6.无日志

    删除 activemq-all-5.10.2.jar 单独添加所需 jar 包 ,日志被覆盖。

  • 相关阅读:
    Git----远程仓库01
    Git--时光穿梭机之删除文件06
    Git----时光穿梭机之撤销修改05
    Git----时光穿梭机之管理修改04
    Git----时光穿梭机之工作区和暂存区03
    Git---时光穿梭机之版本回退02
    Git----时光穿梭机01
    Git---创建版本库
    python自动化之鼠标移动
    python自动化之excel
  • 原文地址:https://www.cnblogs.com/zno2/p/5968743.html
Copyright © 2020-2023  润新知