tags:

views:

54

answers:

0

Guys,

Im using ACE TAO as the CORBA implementation. I would like to find out if anyone know of any options to set Maximum Message Size and Maximum number of Connections.

omniORB has two options for these, giopMaxMsgSize and maxGIOPConnectionPerServer.

Even though TAO has ORBMaxMessageSize and ORBLingerTimeout it causes my server to crash. I dont even know if these are the right options.

This is what the TAO debug output says.

TAO (30232|3086943952) ORB_Core: Unable to initialize Codeset Manager
TAO (30232|3086943952) - Completed initializing the process-wide service context
TAO (30232|3086943952) - Default ORB services initialization begins
TAO (30232|3086943952) - Default ORB services initialization completed
TAO (30232|3086943952) - We are the default ORB ...
TAO (30232|3086943952) - Initializing the orb-specific services
TAO (30232|3086943952) - Setting primary connection timeout hook
TAO (30232|3086943952) - Default_Resource_Factory - unable to find codeset manager factory.
TAO (30232|3086943952) - ORB_Core: Codeset Manager not available
TAO (30232|3086943952) - Loaded default protocol <IIOP_Factory>
TAO (30232|3086943952) - Loaded default protocol <UIOP_Factory>
TAO (30232|3086943952) - Loaded default protocol <SHMIOP_Factory>
TAO (30232|3086943952) - Loaded default protocol <DIOP_Factory>
TAO (30232|3086943952) - Created new ORB <>
TAO (30232|3086943952) - Transport_Cache_Manager_T::purge, Cache size after purging is [0]
TAO (30232|3086943952) - IIOP_Connector::begin_connection, to <wnpcls.econz.co.nz:4000> which should block
TAO (30232|3086943952) - Transport_Connector::wait_for_connection_completion, transport [171625212], Connection not complete.
TAO (30232|3086943952) - Transport_Cache_Manager_T::bind_i, Transport[171625212] @ hash:index{-1408233282:0}
TAO (30232|3086943952) - Transport_Cache_Manager_T::bind_i: Success Transport[171625212] @ hash:index{-1408233282:0}. Cache size is [1]
TAO (30232|3086943952) - Transport_Connector::wait_for_connection_completion, going to wait for connection completion on transport[171625212]
TAO (30232|3086943952) - Leader_Follower[171625212]::wait_for_event, (leader) enter reactor event loop
TAO (30232|3086943952) - IIOP_Connection_Handler::open, The local addr is <172.16.1.30:46404>
TAO (30232|3086943952) - IIOP_Connection_Handler::open, IIOP connection to peer <172.16.1.30:4000> on 6
TAO (30232|3086943952) - Leader_Follower[171625212]::wait_for_event, (leader) exit reactor event loop
TAO (30232|3086943952) - Transport_Connector::wait_for_connection_completion, transport [6], wait done result = 1
TAO (30232|3086943952) - IIOP_Connector::make_connection, new connected connection to <wnpcls.econz.co.nz:4000> on Transport[6]
TAO (30232|3086943952) - Transport[6]::register_handler
TAO (30232|3086943952) - Transport_Connector::connect, opening Transport[6] in TAO_CLIENT_ROLE
TAO (30232|3086943952) - Transport_Connector::connect, got an existing connected Transport[6] in role TAO_CLIENT_ROLE
TAO (30232|3086943952) - Muxed_TMS[6]::request_id, <1>
(30232|3086943952) Error in writing request header
TAO (30232|3086943952) - Transport[6]::generate_request_header, error while marshalling the Request header
TAO (30232|3086943952) - Transport[6]::make_idle
TAO (30232|3086943952) - IIOP_Acceptor::open, address==:4011, options=(null)
TAO (30232|3086943952) - Transport_Connector::connect, got an existing connected Transport[6] in role TAO_CLIENT_ROLE
TAO (30232|3086943952) - Muxed_TMS[6]::request_id, <2>
(30232|3086943952) Error in writing request header
TAO (30232|3086943952) - Transport[6]::generate_request_header, error while marshalling the Request header
TAO (30232|3086943952) - Transport[6]::make_idle
TAO (30232|3086943952) - Connection_Handler[6]::close_connection_eh, purging entry from cache
TAO (30232|3086943952) - Transport[6]::cleanup_queue_i, cleaning up complete queue
TAO (30232|3086943952) - Transport[6]::cleanup_queue_i, discarded 0 messages, 0 bytes.
TAO (30232|3086943952) - Connection_Handler[6]::close_connection_eh, removing from the reactor
TAO (30232|3086943952) - Connection_Handler[6]::close_connection_eh, cancel all timers
TAO (30232|3086943952) - Transport[6]::cleanup_queue_i, cleaning up complete queue
TAO (30232|3086943952) - Transport[6]::cleanup_queue_i, discarded 0 messages, 0 bytes.
TAO (30232|3086943952) - Connection_Handler[6]::close_connection_eh
TAO (30232|3086943952) - Transport[6]::cleanup_queue_i, cleaning up complete queue
TAO (30232|3086943952) - Transport[6]::cleanup_queue_i, discarded 0 messages, 0 bytes.
TAO (30232|3086943952) - Destroying ORB <>

Code Im using is as follows:

#define SC_MAX_SIZE  (1024*1024*4)
char *corbaARGV[12] = { argv[0] };
int args = 1;

char msize[16];
snprintf(msize, sizeof(msize), "%d", SC_MAX_SIZE);
corbaARGV[args + 0] = "-ORBMaxMessageSize";
corbaARGV[args + 1] = strdup(msize);
args += 2;

int timeout = config().GetInteger("Corba_TimeOuts");
mainlog << notice << "CORBA timeout = " << timeout << " seconds." << endl;
char stimeout[16];
snprintf(stimeout, sizeof(stimeout), "%d", timeout);
corbaARGV[args + 0] = "-ORBLingerTimeout";
corbaARGV[args + 1] = strdup(stimeout);
args += 2;

None of the above two works.

Now I also came across a test sample in TAO/tests/Oneway_Timeouts that uses the policies. Can someone shed some light about RELATIVE_RT_TIMEOUT_POLICY_TYPE, CONNECTION_TIMEOUT_POLICY_TYPE, BUFFERING_CONSTRAINT_POLICY_TYPE.

I cant seem to find any documentation about these.