1 / 16

Lime Team

Lime Team. Adam Bazinet Hau San Si Tou. LIME vs. JavaSpace. Similarities: Both are Java-based JavaSpace is written in Java & is a Jini Technology service Both act as a middleware for dynamic communication, coordination & sharing of objects Both are different from a client/server model

kimball
Download Presentation

Lime Team

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Lime Team • Adam Bazinet • Hau San Si Tou

  2. LIME vs. JavaSpace • Similarities: • Both are Java-based • JavaSpace is written in Java & is a Jini Technology service • Both act as a middleware for dynamic communication, coordination & sharing of objects • Both are different from a client/server model • JavaSpace typically runs in the middle tier of a three tier client/server model • Difference: • JavaSpace requires a server to access the space

  3. Lime Console • 3 types of operations: • Access operations such as • out - inserts a tuple in the Lime tuple space. • in - withdraws a tuple from the Lime tuple space, and blocks if no tuple is found. • rd - reads a tuple from the Lime tuple space, and blocks if no tuple is found

  4. Lime Console • Engagement operations such as • Engage Tuple Space – engages the Lime tuple space, i.e., allows sharing with other agents. • Disengage Tuple Space - disengages the Lime tuple space, i.e., makes it private and prohibits sharing with other agents. • Reactive operations such as • Add Strong Reactions – registers a set of strong reactions with the Lime tuple space. • Add Weak Reactions - registers a set of weak reactions with the Lime tuple space.

  5. Lime Console

  6. Chat • Disengage Agent:  Selecting this button will disengage you from the other agents on this host.   • Engage Agent:  Selecting this button will engage you with other agents on your host. Only one of the disengage and engage buttons can be active at once.   • Disengage Host: Selecting this button will disengage the host on which this agent is running from the other hosts in the network.  • Engage Host: Selecting this button will engage this host with others in the network. This allows agents on this host to communicate with Chat programs running on other hosts.

  7. Puzzle

  8. SimpleLime Sample output: >java SimpleLime Hi -mcast off Lime:Factory set to lights.adapters.builtin.TupleSpaceFactory Lime:Lime server murphy:1973 activated Lime:Listening for agents Lime:Agent SimpleLime loaded and started. I wrote the tuple: <Hi> Lime:Shutting down Lime server... Lime:Done.

  9. SimpleLime // Pass Lime arguments (if any) through the Launcher and launch the // LimeServer. In this case, NUMLOCALPARAMETERS is the index of the first // Lime parameter (as opposed to the index of the application parameter) new lime.util.Launcher().launch(args,NUMLOCALPARAMETERS);

  10. SimpleLime // load a SimpleLime, passing the first command line argument as the only parameter LimeServer.getServer().loadAgent("SimpleLime", new String[]{args[0]});

  11. SimpleLime LimeTupleSpace lts = null; ITuple myTuple = new Tuple().addActual(msg); // create the new tuple space (default name) lts = new LimeTupleSpace(); lts.out(myTuple);

  12. SimpleLime // shut down Lime gracefully. LimeServer.getServer().shutDown();

  13. Technical Notes • Multicast packets are automatically sent to hosts on the same subnet • Arbitrary connection and disconnection is currently not supported • A mobile agent cannot write or access tuples using classes that are not present on the file system of the hosting Lime server

  14. Strategy for Implementation • How can you conserve bandwidth in an ad hoc network?

  15. Example Exchange • Writer: “I wrote a tuple (id X) whose hash is H.” Taker: “I want to take a tuple whose hash is H.” Taker: “Send the contents of tuple id X.” Writer: “The contents of tuple id X are . . .” Taker: “Request (id Y) to take tuple id X.” Taker: “Request (id Z) to take tuple id X.” Writer: “Request id Y to take tuple id X granted.” Writer: “Request id Z to take tuple id X not granted.”

  16. Anhinga Spaces • Define the M2M remote interface used between Anhinga Spaces instances under the hood. • Define the Anhinga Spaces client API. Implement Anhinga Spaces. • Demonstrate some applications of Anhinga Spaces.

More Related