Menu

launch_osmoses_recipe

Matías SM

Table of Contents

About this page

This page gives a non-detailed easy to follow recipe to get JADE with OsMoSes up and running.
For more information about using OsMoSes you can read the how to use page.

Launching JADE with OsMoSes

The Recipe

  1. Download the latest OsMoSes distribution file from the distribution files folder.
  2. Uncompress the OsMoSes distribution file in a directory called "jade-osmoses".
  3. Download JADE and place the JAR into "jade-osmoses/jars/" directory.
  4. Download Apache Felix OSGi Framework and place the JAR into "jade-osmoses/jars/" directory.
  5. Download Google Guava (OSGi distribution) and place the JAR (bundle) in "jade-osmoses/osgi_ms/svc_bundles/" directory.
  6. Download Apache Felix Bundle Repository and place the JAR (bundle) in "jade-osmoses/osgi_ms/svc_bundles/" directory.
  7. Go to the directory "jade-osmoses" and type:
    java -cp "jars/*" jade.Boot -services ar.uba.fi.mism.jade.transport.connection.imtp.ImtpConnectionTransportService\;ar.uba.fi.mism.jade.core.mobility.OsgiAgentMobilityService

That's it!! you just launched JADE using OsMoSes instead of its classical mobility service.

Launching an Agent in OsMoSes

The Recipe

  1. Follow the recipe for Launching JADE with OsMoSes but don't launch JADE yet (last step).
  2. Create a directory called "bundles" under "jade-osmoses/osgi_ms/" (the full resulting path will be "jade-osmoses/osgi_ms/bundles/").
  3. Download the bundle ar.uba.fi.osmoses.metrics.lightweight.agent_1.0.0.jar from the example agents directory and place it in "jade-osmoses/osgi_ms/bundles/".
  4. Go to the directory "jade-osmoses" and type:
    java -cp "jars/*" jade.Boot -services ar.uba.fi.mism.jade.transport.connection.imtp.ImtpConnectionTransportService\;ar.uba.fi.mism.jade.core.mobility.OsgiAgentMobilityService "myAgent:ar.uba.fi.osmoses.metrics.lightweight.agent.LightAgent[bundle_sn=ar.uba.fi.osmoses.metrics.lightweight.agent,bundle_v=1.0.0]"

That's it!! you just launched an agent called "myAgent" defined by the class ar.uba.fi.osmoses.metrics.lightweight.agent.LightAgent contained in bundle whose symbolic name is ar.uba.fi.osmoses.metrics.lightweight.agent and version 1.0.0.


Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.