Home Help Center

Icebox issues, help!!!!

dorianleedorianlee Member dorian leeOrganization: pkeProject: passenger information display system
Recently, I rewrite my service code from Ice::service to Ice::Icebox, build all my services as Icebox services and configure them under the same icebox server, because I want to take advantage of Ice's collocation optimizations, which means that if one service is a client of another service, and those services reside in the same IceBox server, then invocations between them can be optimized. But there are three problems I can not figure out the solution.

1. When I stoped one service manually by using IceGridGUI.jar , I can not start it up by make a call to this service, even though I have configured the Icebox's activation as 'on-demand'.

2. I've added a assert in a service and try to make a call to it, it made all the services restart and this is not my expected result. What I want is that if one service crashed , other services will not be effected, and only the crashed service to be restarted by a call to it , supposed to work like 'on-demand'.

3. After I rewrite my services to Icebox services, I can not find a way to pass a command line to the service. In another word, how can I pass parameters to the 'args ' in :
IceBox::start(const ::std::string&, const ::Ice::CommunicatorPtr&, const ::Ice::StringSeq& args)

following is a piece of my application.xml

<service-template id="ServiceTemplate">
<parameter name="module-name"/>
<parameter name="endpoints"/>
<service name="${module-name}" entry="${module-name}Service:create" >
<adapter name="${module-name}SvcAdapter" id="${module-name}Adapter" endpoints="${endpoints}"/>
<property name="--ModuleName" value="${module-name}Service"/>
<property name="--LogFile" value="${module-name}Service.log"/>

<server-template id="SyncreateServerTemplate" >
<parameter name="endpoints" default="tcp -h"/>

<icebox id="ServerInstance" exe="icebox" activation="on-demand">
<service-instance template="ServiceTemplate" module-name="Scada" endpoints="${endpoints}"/>
<service-instance template="ServiceTemplate" module-name="Alarm" endpoints="${endpoints}"/>
<service-instance template="ServiceTemplate" module-name="Ats" endpoints="${endpoints}"/>
<service-instance template="ServiceTemplate" module-name="Authen" endpoints="${endpoints}"/>
<service-instance template="ServiceTemplate" module-name="DataRecording" endpoints="${endpoints}"/>


thanks in advance.......


  • benoitbenoit Rennes, FranceAdministrators, ZeroC Staff Benoit FoucherOrganization: ZeroC, Inc.Project: Ice ZeroC Staff

    #1: IceBox process activation and IceBox service activation is not the same thing. The "on-demand" activation only applies to the process not to services. Services which are stopped through the GUI will have to also be restarted through the GUI manually: they can't be activated on-demand, this isn't currently supported.

    #2: an assert causes the processes to abort, this is normal behavior for a C++ process and IceBox doesn't change this behavior.

    #3: Only arguments prefixed with --<service name> are passed to the service and transformed into properties. In your case, you should pass properties prefixed with --Scada, --Alarm, etc. for the Scada, Alarm, etc services.

Sign In or Register to comment.