Hi,
Thanks for the additional information. Unfortunately they do not explain the problem you have: as I said I would have expected possible problems in code migration, but not in this point. We have to perform some deeper investigation. I'll let you know as soon as we have some result.
Bye,
Giovanni
Da: Walison Jose de Deus [mailto:walisonjose16 at hotmail.com]
Inviato: luned? 10 marzo 2014 18:28
A: Caire Giovanni; jade-develop at avalon.tilab.com
Oggetto: RE: R: R: R: R: [jade-develop] R: Android mobility - Normal container - Problem with RuntimeService
Hello,
Thanks for the instructions. I carried out the instructions and got the following reply, where the words in bold is the class AgentMobilityService.I performed a new test, but now running the normal container on the computer rather than the android device and got the same answer:
Platform services DUMP
-------------------------------------------------------------
Service entry jade.core.mobility.AgentMobility
- Name = jade.core.mobility.AgentMobility
- Class = jade.core.mobility.AgentMobilityService
- Slices:
- Slice Container-1
- Class = jade.core.mobility.AgentMobilityProxy
- Associated node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Inner node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Slice Main-Container
- Class = jade.core.mobility.AgentMobilityProxy
- Associated node = Main-Container
- Inner node = Main-Container
Service entry jade.core.management.AgentManagement
- Name = jade.core.management.AgentManagement
- Class = jade.core.management.AgentManagementService
- Slices:
- Slice Container-1
- Class = jade.core.management.AgentManagementProxy
- Associated node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Inner node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Slice Main-Container
- Class = jade.core.management.AgentManagementProxy
- Associated node = Main-Container
- Inner node = Main-Container
Service entry jade.core.messaging.Messaging
- Name = jade.core.messaging.Messaging
- Class = jade.core.messaging.MessagingService
- Slices:
- Slice Container-1
- Class = jade.core.messaging.MessagingProxy
- Associated node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Inner node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Slice Main-Container
- Class = jade.core.messaging.MessagingProxy
- Associated node = Main-Container
- Inner node = Main-Container
Service entry jade.core.event.Notification
- Name = jade.core.event.Notification
- Class = jade.core.event.NotificationService
- Slices:
- Slice Container-1
- Class = jade.core.event.NotificationProxy
- Associated node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Inner node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Slice Main-Container
- Class = jade.core.event.NotificationProxy
- Associated node = Main-Container
- Inner node = Main-Container
Service entry jade.core.resource.ResourceManagement
- Name = jade.core.resource.ResourceManagement
- Class = jade.core.resource.ResourceManagementService
- Slices:
- Slice Container-1
- Class = jade.core.resource.ResourceManagementProxy
- Associated node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Inner node = [Container-1, 14201479, jicp://191.224.203.80:1099]
- Slice Main-Container
- Class = jade.core.resource.ResourceManagementProxy
- Associated node = Main-Container
- Inner node = Main-Container
Bye,
Walison
________________________________
From: giovanni.caire at telecomitalia.it
To: walisonjose16 at hotmail.com
CC: jade-develop at avalon.tilab.com
Date: Mon, 10 Mar 2014 10:30:42 +0100
Subject: R: R: R: R: [jade-develop] R: Android mobility - Normal container - Problem with RuntimeService
Hi,
To investigate the problem you should do the following:
1) Add the misc add-on to the classpath of the Main Container. By doing that, when you launch the Main-Container you should see an additional agent called monitor-Main-Container in the RMA GUI.
2) Launch Container-1 in the first Android device and check that it appears in the RMA GUI.
3) Using the RMA GUI launch a DummyAgent.
4) Use the DummyAgent GUI to inspect the Main Container internal structures by interacting with the monitor-Main-Container agent as shown in the picture below.
[cid:image001.jpg at 01CF3EEC.B9593930]
5) Click the Send button.
6) Look at the output of the Main Container: you should see something like that:
-------------------------------------------------------------
Platform services DUMP
-------------------------------------------------------------
Service entry jade.core.mobility.AgentMobility
- Name = jade.core.mobility.AgentMobility
- Class = jade.core.mobility.AgentMobilityService
- Slices:
- Slice Main-Container
- Class = jade.core.mobility.AgentMobilityProxy
- Associated node = Main-Container
- Inner node = Main-Container
Service entry jade.core.management.AgentManagement
- Name = jade.core.management.AgentManagement
- Class = jade.core.management.AgentManagementService
- Slices:
- Slice Main-Container
- Class = jade.core.management.AgentManagementProxy
- Associated node = Main-Container
- Inner node = Main-Container
Service entry jade.core.messaging.Messaging
- Name = jade.core.messaging.Messaging
- Class = jade.core.messaging.MessagingService
- Slices:
- Slice Main-Container
- Class = jade.core.messaging.MessagingProxy
- Associated node = Main-Container
- Inner node = Main-Container
Service entry jade.core.event.Notification
- Name = jade.core.event.Notification
- Class = jade.core.event.NotificationService
- Slices:
- Slice Main-Container
- Class = jade.core.event.NotificationProxy
- Associated node = Main-Container
- Inner node = Main-Container
Service entry jade.core.resource.ResourceManagement
- Name = jade.core.resource.ResourceManagement
- Class = jade.core.resource.ResourceManagementService
- Slices:
- Slice Main-Container
- Class = jade.core.resource.ResourceManagementProxy
- Associated node = Main-Container
- Inner node = Main-Container
-------------------------------------------------------------
7) Check if the AgentMobilityService entry has a slice associated to Container-1
Let me know and bye,
Giovanni
Da: Walison Jose de Deus [mailto:walisonjose16 at hotmail.com]
Inviato: venerd? 7 marzo 2014 19:41
A: Caire Giovanni; jade-develop at avalon.tilab.com
Oggetto: RE: R: R: R: [jade-develop] R: Android mobility - Normal container - Problem with RuntimeService
Hi,
That's it.
The execution scenario is a PC where the Main Container squeegee and two androids devices that are connected on the same wifi network.
Initially, I run the RMA GUI on the PC through the command:
java jade.Boot local-host-192.168.43.171-gui
Then run on a android device an application to create a normal container, where the agent moves. This container is successfully created and can view it in the RMA GUI;
Then in another android device run another application to create another agent in a normal container ("Container-2") which will move to the "Container-1". This agent is created successfully and both he and the container "Container-2" are visible in the RMA GUI;
Now both before and after the implementation of the method for the movement of the agent for the "Container-1" all containers, as the same agent are visible in the RMA GUI. In the test I conducted the agent does not move to the "Container-1".
Now conducting a test using two emulators to represent the two android devices, so I can monitor the execution was returned to me the following error when getting out of the agent:
E / jade.core.mobility.AgentMobility (1067): Destination Container-1 does not exist or does not support mobility
I think maybe the problem is in creating the container or in the same communication with the platform. To create the container I'm using this method:
private void startContainer(final String nickname, Profile profile,
final RuntimeCallback<AgentController> agentStartupCallback) {
sd.createAgentContainer(profile, new RuntimeCallback<AgentContainerHandler>() {
@Override
public void onFailure(Throwable arg0) {
// TODO Auto-generated method stub
System.out.println("\n\n deu erro...");
}
@Override
public void onSuccess(AgentContainerHandler arg1) {
System.out.println("\n\n Container criado...");
}
});
To set the profile information:
final Properties profile = new Properties();
profile.setProperty(Profile.MAIN_HOST, host);
profile.setProperty(Profile.MAIN_PORT, port);
profile.setProperty(Profile.MAIN, Boolean.FALSE.toString());
profile.setProperty(Profile.JVM, Profile.ANDROID);
if (AndroidHelper.isEmulator()) {
// Emulator: this is needed to work with emulated devices
profile.setProperty(Profile.LOCAL_HOST, AndroidHelper.LOOPBACK);
} else {
profile.setProperty(Profile.LOCAL_HOST,
AndroidHelper.getLocalIPAddress());
}
// Emulator: this is not really needed on a real device
profile.setProperty(Profile.LOCAL_PORT, "2000");
Where host is "192.168.43.171" and port is "1099".
what u think?
Bye
Walison
________________________________
From: giovanni.caire at telecomitalia.it
To: walisonjose16 at hotmail.com; jade-develop at avalon.tilab.com
Date: Fri, 7 Mar 2014 10:03:59 +0100
Subject: R: R: R: [jade-develop] R: Android mobility - Normal container - Problem with RuntimeService
Hi,
Let me try to recap.
You are now in a situation with:
- The Main Container running somewhere in the fixed Network (likely in your PC)
- Container-1 running in Android device 1
- Container-2 running in Android device 2
- An agent in Container-2 that calls doMove(new ContainerID("Container-1", null));
Is that correct?
If yes, do you actually see the three containers (main, container-1 and container-2) in the RMA GUI?
Are you sure they are all there BEFORE the agent calls doMove()?
Bye,
Giovanni
Da: Walison Jose de Deus [mailto:walisonjose16 at hotmail.com]
Inviato: mercoled? 5 marzo 2014 03:44
A: Caire Giovanni; jade-develop at avalon.tilab.com
Oggetto: RE: R: R: [jade-develop] R: Android mobility - Normal container - Problem with RuntimeService
Hi,
Thanks for the tip, it worked perfectly and the execution of the agent is begining successfully. Now, I'm having trouble trying to move an agent between normal containers on android devices. For this I created another identical application which should create a normal container on a android device. I use the following method to launch normal container and works properly:
private void startContainer(final String nickname, Profile profile,
final RuntimeCallback<AgentController> agentStartupCallback) {
sd.createAgentContainer(profile, new RuntimeCallback<AgentContainerHandler>() {
@Override
public void onFailure(Throwable arg0) {
// TODO Auto-generated method stub
System.out.println("\n\n deu erro...");
}
@Override
public void onSuccess(AgentContainerHandler arg1) {
System.out.println("\n\n Container criado...");
}
});
Then run another application on another device, which also throws a normal container and an agent in the same, and whose only action the agent is trying to move into a normal container to another device, the application returns me the following message:...
E/jade.core.mobility.AgentMobility(1067): Destination Container-1 does not exist or does not support mobility
I'm using the following method to move the agent:
public void moveCont1(){
addBehaviour(new OneShotBehaviour(this) {
@Override
public void action() {
String nome = "Container-1";
ContainerID dest = new ContainerID();
dest.setName(nome);
}
});
}
What do you think could be wrong?
Bye,
Walison
Questo messaggio e i suoi allegati sono indirizzati esclusivamente alle persone indicate. La diffusione, copia o qualsiasi altra azione derivante dalla conoscenza di queste informazioni sono rigorosamente vietate. Qualora abbiate ricevuto questo documento per errore siete cortesemente pregati di darne immediata comunicazione al mittente e di provvedere alla sua distruzione, Grazie.
This e-mail and any attachments is confidential and may contain privileged information intended for the addressee(s) only. Dissemination, copying, printing or use by anybody else is unauthorised. If you are not the intended recipient, please delete this message and any attachments and advise the sender by return e-mail, Thanks.
Rispetta l'ambiente. Non stampare questa mail se non ? necessario.
:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://avalon.cselt.it/pipermail/jade-develop/attachments/20140313/b370a1ba/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 37843 bytes
Desc: image001.jpg
URL: <http://avalon.cselt.it/pipermail/jade-develop/attachments/20140313/b370a1ba/attachment-0001.jpg>