INTRODUCTION
Overview
Download and Install
Quick Start
Documentation
Publications

NONFRAMEWORK CODE
Driver Interfaces
Drivers
Libraries
Utilities

FRAMEWORK CODE
Interfaces
Components
Libraries
Utilities

Full Software Listings

DEVELOPER
Tutorials
Examples
Dev Guide
Dashboard

PEOPLE
Contributors
Users

SourceForge.net Logo
Project
Download
Mailing lists

 

         

RegistryClean
[UtilitiesStand-Alone ComponentsC++Linux]

A utility to remove unreachable components from the IceGrid Registry. More...

A utility to remove unreachable components from the IceGrid Registry.

Provided Interfaces
  • none
Required Interfaces
  • IceGrid/Admin

The IceGrid registry maintains a database of registered components (actually it's a list of object adapater ID's). The registry has no way of checking if a component is actually running at any given time. Component information will never be removed from the list by the registry and, because the database storage is persistent, will be reloaded if the registry is restarted. This means that after a while the registry will contain a long list of components which ran in the past but are not currently on line. The operation of the registry itself is not noticibly affected but having a long list of defunct components may be inconvinient for other reasons. For example, the display of RegistryView becomes cluttered and its response time slows down as it has to individually ping all the registered components.

One possible solution is to periodically stop the registry and delete the contents of its database directory. One has to make sure though that no components are running at the time because they will not be accessible after the database purge.

Another approach is to determine which of the registered components are not currently running and remove them from the registry list by using the IceGrid/Admin interface. This is what RegistryClean does by executing the following steps:

  1. get a list of all registered adapters from the IceGrid Registry
  2. ping the Home interface on each adapter (component)
  3. tell the registry to unregister those adapters which could not be reached.
  4. exit

Notice that it is impossible to ping a component (i.e. an Ice object adapter). One must ping a specific interface (i.e. an Ice object). All Orca components using libOrcaIce provide orca_interface_home interface which we can ping to determine if the component is reachable.

The registy may contain adapter ID's of which don't belong to Orca components. These are left in the registy if their ID does not follow the 'platform/component' pattern (i.e. if ID does not contain a slash character).

Operation

You can run this utility manualy or as a periodic job from cron. The following crontab line runs the utility daily at 6 am.

0 6     * * *   /opt/orca-2.0.0rc3+/bin/registryclean /opt/orca-2.0.0rc3+/cfg/registryclean.cfg

The Admin interface of the IceGrid registry is disabled by default. To enable it, include the following line in the registry configuration file. On a publically accessible network there is of course a security risk which you must consider.

IceGrid.Registry.Admin.Endpoints=default
Configuration
  • Ice.Override.ConnectTimeout (int) [ms]
    • The timeout for deciding when the components listed in the registry are not reachable.
    • Default: 500

An example configuration file is installed into [ORCA-INSTALL-DIR]/share/orca/cfg/ directory.

Authors
Alex Makarenko
 

Webmaster: Tobias Kaupp (tobasco at users.sourceforge.net)


Generated for Orca Robotics by  doxygen 1.4.5