Open icemagno opened 4 years ago
@michaelrfraser please help me
@icemagno just checking this out now...
Ok, so firstly my apologies. I haven't been in the portico codebase for at least a year now and I couldn't quite remember what was currently in the master branch.
Previously portico used to run in a purely decentralised fashion, meaning that there was no central rtiexec process required. However about half way through 2018 we moved back to having a central RTI process to implement some advanced features (such as encryption etc).
This means that rtiexec needs to be running on the network first before any federates start up. To start rtiexec:
/home/portico/dist/portico-2.2.0
bin/rtiexec.sh
Once started you should be able to switch back to your original termal and run the federate example.
Best Regards,
Michael
It is a great News! So close to my intent to crate a Docker image running a central RTI.
So..... can I just run the rtiexec ANYWHERE in my network and run any federates in another machines? Are they using broadcasting to find each other?
@timpokorny @michaelrfraser Good! the rtiexec.sh
solved the problem. But....
Now, after trying again to run the example (in another machine) I have this error in the CRTI machine:
00:58:27,175 INFO portico.rti: Starting the RTI
00:58:27,176 INFO portico.rti: Starting connection tcp
00:58:29,198 INFO portico.rti: Starting connection jvm
00:58:29,301 INFO portico.rti: Starting connection multicast
00:58:33,593 INFO portico.rti: RTI is up. Connections active and ready for bizness!
rti /> 01:01:32,060 INFO portico.rti: ATTEMPT Creating federation name=ExampleFederation
01:01:32,115 INFO portico.rti: SUCCESS Created federation name=ExampleFederation
01:01:32,178 INFO portico.rti.{ExampleFederation}: SUCCESS Federate [exampleFederate] joined federation [Ex ampleFederation] with handle [1]
01:01:32,194 INFO portico.rti: Federate [exampleFederate] joined federation via connection multicast (type: Multicast)
01:01:32,225 INFO portico.rti.{ExampleFederation}: SUCCESS Registered sync point [ReadyToRun] by [exampleFe derate]
01:01:32,225 WARN portico.rti.{ExampleFederation}: Error sending message [AnnounceSyncPoint] via connection [multicast]
org.portico.lrc.compat.JRTIinternalError: Async Messages no longer supported - move to Notificatins
at org.portico2.common.network.Connection.sendControlRequest(Connection.java:257) ~[portico.jar:?]
at org.portico2.rti.RtiConnection.sendControlRequest(RtiConnection.java:99) ~[portico.jar:?]
at org.portico2.rti.federation.Federation$OutgoingMessageProcessor.sendMessage(Federation.java:521) [portico.jar:?]
at org.portico2.rti.federation.Federation$OutgoingMessageProcessor.run(Federation.java:502) [portico .jar:?]
... and in the Example Federate:
root@portico:/opt/portico-2.2.0/examples/java/ieee1516e# ./linux.sh execute
ExampleFederate : Creating RTIambassador
ExampleFederate : Connecting...
02:03:56,148 INFO portico.lrc: Creating new LRC
02:03:56,151 INFO portico.lrc: Portico version: 2.2.0 (build 0)
02:03:56,152 INFO portico.lrc: Interface: IEEE1516e
02:04:00,701 INFO portico.lrc: LRC initialized (HLA version: IEEE1516e)
ExampleFederate : Creating Federation...
02:04:03,520 INFO portico.lrc: SUCCESS Created federation execution [ExampleFederation] with handle 1
ExampleFederate : Created Federation
02:04:03,661 INFO portico.lrc: SUCCESS Federate [exampleFederate] joined to federation [ExampleFederation] with handle [1]
ExampleFederate : Joined Federation as exampleFederate
FederateAmbassador: Successfully registered sync point: ReadyToRun
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
Still waiting for announce
... forever.
How to change to TCP connection
instead MULTICAST
?
PS: Attention to the typo in Async Messages no longer supported - move to Notificatins
A similar error:
19:01:13,669 WARN portico.rti.{BasicFederation}: Error sending message [DiscoverObject] via connection [multicast]
org.portico.lrc.compat.JRTIinternalError: Async Messages no longer supported - move to Notificatins
at org.portico2.common.network.Connection.sendControlRequest(Connection.java:257) ~[portico.jar:?]
at org.portico2.rti.RtiConnection.sendControlRequest(RtiConnection.java:99) ~[portico.jar:?]
at org.portico2.rti.federation.Federation$OutgoingMessageProcessor.sendMessage(Federation.java:521) [portico.jar:?]
at org.portico2.rti.federation.Federation$OutgoingMessageProcessor.run(Federation.java:502) [portico.jar:?]
... and a eternal loop in federete execution screen:
19:01:13,749 INFO portico.lrc: SUCCESS Updated object [3] with attributes [739] (RO)
Well.... I've decided to rollback to the v2.1.0 and have no centralized RTI to run.
BUT...
the tests still having error. Now it seems related to the SOM or FOM. This is a local one instance run:
root@portico:/opt/portico-2.1.0/examples/java/ieee1516e# ./linux.sh execute
ExampleFederate : Creating RTIambassador
ExampleFederate : Connecting...
ExampleFederate : Creating Federation...
-------------------------------------------------------------------
GMS: address=portico-9905, cluster=ExampleFederation, physical address=172.17.0.3:46641
-------------------------------------------------------------------
ExampleFederate : Created Federation
ExampleFederate : Joined Federation as exampleFederate
FederateAmbassador: Successfully registered sync point: ReadyToRun
FederateAmbassador: Synchronization point announced: ReadyToRun
ExampleFederate : >>>>>>>>>> Press Enter to Continue <<<<<<<<<<
ExampleFederate : Achieved sync point: ReadyToRun, waiting for federation...
FederateAmbassador: Federation Synchronized: ReadyToRun
ExampleFederate : Time Policy Enabled
hla.rti1516e.exceptions.AttributeNotDefined: org.portico.lrc.compat.JAttributeNotDefined: PUBLISH-OBJECT: attribute [-1] not defined in object class [HLAobjectRoot.Food.Drink.Soda]
at org.portico.impl.hla1516e.Rti1516eAmbassador.publishObjectClassAttributes(Rti1516eAmbassador.java:1161)
at ieee1516e.ExampleFederate.publishAndSubscribe(ExampleFederate.java:403)
at ieee1516e.ExampleFederate.runFederate(ExampleFederate.java:281)
at ieee1516e.ExampleFederate.main(ExampleFederate.java:560)
Caused by: org.portico.lrc.compat.JAttributeNotDefined: PUBLISH-OBJECT: attribute [-1] not defined in object class [HLAobjectRoot.Food.Drink.Soda]
at org.portico.lrc.services.object.data.InterestManager.register(InterestManager.java:160)
at org.portico.lrc.services.object.data.InterestManager.register(InterestManager.java:108)
at org.portico.lrc.services.object.data.InterestManager.publishObjectClass(InterestManager.java:619)
at org.portico.lrc.services.pubsub.handlers.outgoing.PublishObjectClassHandler.process(PublishObjectClassHandler.java:110)
at org.portico.utils.messaging.MessageSink.process(MessageSink.java:187)
at org.portico.impl.hla1516e.Impl1516eHelper.processMessage(Impl1516eHelper.java:130)
at org.portico.impl.hla1516e.Rti1516eAmbassador.processMessage(Rti1516eAmbassador.java:5559)
at org.portico.impl.hla1516e.Rti1516eAmbassador.publishObjectClassAttributes(Rti1516eAmbassador.java:1135)
... 3 more
root@portico:/opt/portico-2.1.0/examples/java/ieee1516e#
Tried my own Federate and it worked. I think this problem is only in ExampleFederate.
Well.... I've decided to rollback to the v2.1.0 and have no centralized RTI to run.
BUT...
the tests still having error. Now it seems related to the SOM or FOM. This is a local one instance run:
root@portico:/opt/portico-2.1.0/examples/java/ieee1516e# ./linux.sh execute ExampleFederate : Creating RTIambassador ExampleFederate : Connecting... ExampleFederate : Creating Federation... ------------------------------------------------------------------- GMS: address=portico-9905, cluster=ExampleFederation, physical address=172.17.0.3:46641 ------------------------------------------------------------------- ExampleFederate : Created Federation ExampleFederate : Joined Federation as exampleFederate FederateAmbassador: Successfully registered sync point: ReadyToRun FederateAmbassador: Synchronization point announced: ReadyToRun ExampleFederate : >>>>>>>>>> Press Enter to Continue <<<<<<<<<< ExampleFederate : Achieved sync point: ReadyToRun, waiting for federation... FederateAmbassador: Federation Synchronized: ReadyToRun ExampleFederate : Time Policy Enabled hla.rti1516e.exceptions.AttributeNotDefined: org.portico.lrc.compat.JAttributeNotDefined: PUBLISH-OBJECT: attribute [-1] not defined in object class [HLAobjectRoot.Food.Drink.Soda] at org.portico.impl.hla1516e.Rti1516eAmbassador.publishObjectClassAttributes(Rti1516eAmbassador.java:1161) at ieee1516e.ExampleFederate.publishAndSubscribe(ExampleFederate.java:403) at ieee1516e.ExampleFederate.runFederate(ExampleFederate.java:281) at ieee1516e.ExampleFederate.main(ExampleFederate.java:560) Caused by: org.portico.lrc.compat.JAttributeNotDefined: PUBLISH-OBJECT: attribute [-1] not defined in object class [HLAobjectRoot.Food.Drink.Soda] at org.portico.lrc.services.object.data.InterestManager.register(InterestManager.java:160) at org.portico.lrc.services.object.data.InterestManager.register(InterestManager.java:108) at org.portico.lrc.services.object.data.InterestManager.publishObjectClass(InterestManager.java:619) at org.portico.lrc.services.pubsub.handlers.outgoing.PublishObjectClassHandler.process(PublishObjectClassHandler.java:110) at org.portico.utils.messaging.MessageSink.process(MessageSink.java:187) at org.portico.impl.hla1516e.Impl1516eHelper.processMessage(Impl1516eHelper.java:130) at org.portico.impl.hla1516e.Rti1516eAmbassador.processMessage(Rti1516eAmbassador.java:5559) at org.portico.impl.hla1516e.Rti1516eAmbassador.publishObjectClassAttributes(Rti1516eAmbassador.java:1135) ... 3 more root@portico:/opt/portico-2.1.0/examples/java/ieee1516e#
Tried my own Federate and it worked. I think this problem is only in ExampleFederate.
I am new to this RTI and I have to run this RTI with a third party application. I am facing same issue while running the java\ieee1516e example in portico project. Could you please tell me how you solved this issue. Waiting for your reply. Regards
After create the sandbox ( ./ant sandbox ) I try to run a test but receive the follow error:
What may be wrong?