gpt4 book ai didi

java - 无法使用 C++ TAO 客户端连接到 java 1.3 NamingService

转载 作者:行者123 更新时间:2023-12-01 15:45:23 27 4
gpt4 key购买 nike

我一直在尝试让我的 C++ TAO (v1.6) 客户端连接到 java tnameserv JDK1.3上运行。
但是C++ TAO客户端无法解析命名服务。它抛出以下异常:

system exception, ID 'IDL:omg.org/CORBA/UNKNOWN:1.0'<br/>
Unknown vendor minor code id (53550000), minor code = 53550004, completed = MAYBE

这是我收到的调试日志

TAO (4144|5228) Completed initializing the process-wide service context<br/>
TAO (4144|5228) Default ORB services initialization begins<br/>
TAO (4144|5228) Default ORB services initialization completed<br/>
TAO (4144|5228) We are the default ORB ...<br/>
TAO (4144|5228) Initializing the orb-specific services<br/>
TAO (4144|5228) Default_Resource_Factory - codeset manager=004AE5C0<br/>
TAO (4144|5228) - Codeset_Manager_i::init_ccs, Loaded Codeset translator , ncs = 00010001 tcs = 05010001<br/>
TAO (4144|5228) - UTF16_BOM_Translator: forceBE 0<br/>
TAO (4144|5228) Loaded default protocol <br/>
TAO (4144|5228) created new ORB <><br/>
TAO (4144|5228) - Transport_Cache_Manager::find_i, no idle transport is available<br/>
TAO (4144|5228) - Transport_Cache_Manager::fill_set_i, current_size = 0, cache_maximum = 512<br/>
TAO (4144|5228) - IIOP_Connector::begin_connection, to which should block<br/>
TAO (4144|5228) - Transport_Connector::wait_for_connection_completion, going to wait for connection completion on transport[10603568]<br/>
TAO (4144|5228) - Leader_Follower[10603568]::wait_for_event, (leader) enter reactor event loop<br/>
TAO (4144|5228) - IIOP_Connection_Handler::open, The local addr is <127.0.0.1:54768><br/>
TAO (4144|5228) - IIOP_Connection_Handler::open, IIOP connection to peer <127.0.0.1:2323> on 512<br/>
TAO (4144|5228) - Leader_Follower[10603568]::wait_for_event, (leader) exit reactor event loop<br/>
TAO (4144|5228) - Transport_Connector::wait_for_connection_completion, transport [512], wait done result = 1<br/>
TAO (4144|5228) - IIOP_Connector::make_connection, new connected connection to on Transport[512]<br/>
TAO (4144|5228) - Transport_Cache_Manager::bind_i, Transport[512]; hash 2130708756<br/>
TAO (4144|5228) - Transport_Cache_Manager::bind_i, cache size is [1]<br/>
TAO (4144|5228) - Transport[512]::register_handler<br/>
TAO (4144|5228) - Transport_Connector::connect, opening Transport[512] in TAO_CLIENT_ROLE<br/>
TAO (4144|5228) - Codeset_Manager_i::set_tcs, No codeset component in profile<br/>
TAO (4144|5228) - Muxed_TMS[512]::request_id, <1><br/>
TAO (4144|5228) - Codeset_Manager_i::generate_service_context, using tcs_c = 00010001, tcs_w = 00010109<br/>
TAO (4144|5228) - GIOP_Message_Base::dump_msg, send GIOP v1.0 msg, 108 data bytes, my endian, Type Request[1]<br/>
TAO (4144|5228) - Transport[512]::drain_queue_helper, sending 1 buffers<br/>
TAO (4144|5228) - Transport[512]::drain_queue_helper, buffer 0/1 has 120 bytes<br/>
TAO - Transport[512]::drain_queue_helper (0/120) - HEXDUMP 120 bytes<br/>
47 49 4f 50 01 00 01 00 6c 00 00 00 01 00 00 00 GIOP....l.......<br/>
01 00 00 00 0c 00 00 00 01 00 4a 00 01 00 01 00 ..........J.....<br/>
09 01 01 00 01 00 00 00 01 00 00 00 0b 00 00 00 ................<br/>
4e 61 6d 65 53 65 72 76 69 63 65 00 06 00 00 00 NameService.....<br/>
5f 69 73 5f 61 00 00 00 00 00 00 00 28 00 00 00 _is_a.......(...<br/>
49 44 4c 3a 6f 6d 67 2e 6f 72 67 2f 43 6f 73 4e IDL:omg.org/CosN<br/>
61 6d 69 6e 67 2f 4e 61 6d 69 6e 67 43 6f 6e 74 aming/NamingCont<br/>
65 78 74 3a 31 2e 30 00 ext:1.0.<br/>
TAO (4144|5228) - Transport[512]::drain_queue_helper, end of data<br/>
TAO (4144|5228) - Transport[512]::cleanup_queue, byte_count = 120<br/>
TAO (4144|5228) - Transport[512]::cleanup_queue, after transfer, bc = 0, all_sent = 1, ml = 0<br/>
TAO (4144|5228) - Transport[512]::drain_queue_helper, byte_count = 120, head_is_empty = 1<br/>
TAO (4144|5228) - Transport[512]::drain_queue_i, helper retval = 1<br/>
TAO (4144|5228) - Transport[512]::make_idle<br/>
TAO (4144|5228) - Leader_Follower[512]::wait_for_event, (leader) enter reactor event loop<br/>
TAO (4144|5228) - Transport[512]::handle_input<br/>
TAO (4144|5228) - Transport[512]::process_queue_head, 0 enqueued<br/>
TAO (4144|5228) - Transport[512]::handle_input_parse_data, enter <br/>
TAO (4144|5228) - Transport[512]::handle_input_parse_data, read 236 bytes<br/>
TAO (4144|5228) - GIOP_Message_Base::dump_msg, recv GIOP v1.0 msg, 224 data bytes, other endian, Type Reply[6]<br/>
TAO (4144|5228) - Leader_Follower[512]::wait_for_event, (leader) exit reactor event loop<br/>
TAO (4144|5228) - Synch_Twoway_Invocation::handle_system_exception<br/>
TAO (4144|5228) - Synch_Twoway_Invocation::handle_system_exception, about to raise<br/>
(4144|5228) EXCEPTION, Exception caught:<br/>
<b>system exception, ID 'IDL:omg.org/CORBA/UNKNOWN:1.0'<br/>
Unknown vendor minor code id (53550000), minor code = 53550004, completed = MAYBE</b><br/>
Destroying ORB <><br/>
TAO (4144|5228) - Connection_Handler[512]::close_connection_eh, purging entry from cache<br/>
TAO (4144|5228) - Transport[512]::cleanup_queue_i, cleaning up complete queue<br/>
TAO (4144|5228) - Transport[512]::cleanup_queue_i, discarded 0 messages, 0 bytes<br/>
TAO (4144|5228) - Connection_Handler[512]::close_connection_eh, removing from the reactor<br/>
TAO (4144|5228) - Connection_Handler[512]::close_connection_eh, cancel all timers<br/>
TAO (4144|5228) - Transport[512]::cleanup_queue_i, cleaning up complete queue<br/>
TAO (4144|5228) - Transport[512]::cleanup_queue_i, discarded 0 messages, 0 bytes<br/>
TAO (4144|5228) - Connection_Handler[512]::close_connection_eh<br/>
TAO (4144|5228) - Transport[512]::cleanup_queue_i, cleaning up complete queue<br/>
TAO (4144|5228) - Transport[512]::cleanup_queue_i, discarded 0 messages, 0 bytes

请帮我解决这个问题。谢谢。

最佳答案

看起来tnameserv组件正在抛出一个非标准的SystemException。这总是被 CORBA spec 所阻止。 :

Vendors may define non-standard system exceptions, but these exceptions are discouraged because they are non-portable. A non-standard system exception, when passed to an ORB that does not recognize it, shall be presented by that ORB as an UNKNOWN standard system exception. The minor code and completion status from the unrecognized exception shall be preserved in the UNKNOWN exception.

不过,很难判断供应商特定的次要代码 (53550000) 代表什么。 Oracle/Sun 似乎没有关于其代码的文档,因此我建议打开 tnameserv 上的日志记录以查看它返回给您的内容。

我还建议您编写一个快速的 Java 1.3 CORBA 客户端,它与 C++ TAO 客户端执行相同的操作,然后看看是否有效。如果是这样,则您的 TAO C++ 客户端遇到了互操作性问题。如果它不起作用,您至少会看到神秘的 SystemException 的详细信息,它可能会引导您找到解决方案。

关于java - 无法使用 C++ TAO 客户端连接到 java 1.3 NamingService,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7144945/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com