Hi,
You need to establish a session with the registry to obtain a proxy for the IceGrid::Admin interface. The session will also allow you to register observers to receive updates from the IceGrid registry and nodes.
Here's how to create an IceGrid admin session and get the admin proxy with Python and IcePy:
Code:
#!/usr/bin/env python
import sys, Ice, IceGrid
communicator = Ice.initialize(sys.argv)
registry = IceGrid.RegistryPrx.uncheckedCast(communicator.stringToProxy("DemoIceGrid/Registry"))
session = registry.createAdminSession("user", "passord")
admin = session.getAdmin()
print admin.getAllServerIds()
session.destroy()
communicator.destroy()
You'll need to pass the appropriate --Ice.Defaut.Locator=<proxy of the locator> command line option to execute this script.
Cheers,
Benoit.