Can anyone tell me how to find available agent containers through java code? I am using the JADE agent framework and I have figured out how to create new containers but not find existing containers (so that agents can be deployed in them).
相关问题
- Mounting a gcePersistentDisk kubernetes volume is
- C++ boost::thread and automatically locking contai
- Docker Named Volume with targeting windows local f
- Container of Different Functors
- Supporting “for each” on custom const native C++ c
相关文章
- Override env values defined in container spec
- Adding Shadows at the bottom of a container in flu
- Finding any element with specific first coordinate
-
C++, how to correctly copy std::vector
in c - AWS Lambda Container destroy event
- How was the container created and how does it work
- Docker pull fails on Windows 10 in Windows Contain
- Accidentally drained all nodes in Kubernetes (even
There are two ways of doing this, depending on whether you want to receive the information via an ongoing service or the current snapshot in a message.
To get a snapshot of the IDs of the currently available agent containers, send a Request message to the Agent Management Service (AMS) and wait for its reply. Using the JADE Management Ontology and the QueryPlatformLocationsAction term, the sending and receiving methods would be:
To get this information as an ongoing service, and to receive the ContainerID of each container as it registers with the AMS, create a Behaviour that extends the AMSSubscriber. Register a handler for the AddedContainer event and you will be able to access the ContainerID of the newly available container:
Hope this helps,
Russ