IntegrationService

= IntegrationService =

Basic Info

 * Summary: Integration Service is a Robust facility to provide management for running dynamic plugins used for extending connections into the grid from external applications.
 * Developer Sponsor(s): BlueWall Information Technologies, LLC (BlueWall) jamesh@bluewallgroup.com / IRC - "BlueWall" on #opensim-dev, #opensim
 * Start Date: March 31, 2012
 * Branches Targeted: OpenSim master/development (after evaluation)
 * Commercial: Not specifically, but of general interest to adopters to help them integrate their external projects with OpenSimulator
 * Code Repository: https://github.com/BlueWall/opensim/tree/integration will send to opensimulator.org as a branch soon

Idea
Integration Service for Robust is a facility to manage dynamic plugins, allowing external applications to be integrated with the OpenSimulator grid. The service helps the application developer provide clean APIs for their OpenSimulator integration projects by supplying a convenient framework to manage plugins that reside outside of OpenSimulator core. Their applications may be easily distributed across other sites without the need to interface directly to the underlying database structure. The developer has access to the OpenSimulator framework, including database migrations, easing maintenance tasks for users and administrators of their applications. This framework also opens the possibility for “crowd sourcing” standard APIs and libraries for applications such as web integration for popular CMS like Drupal, Joomla and Django and building API libraries for popular programming languages. These would offer a level of abstraction from the OpenSimulator core project to help minimize conflicts with external projects when core changes are needed. With the user-base migrating to V3 based viewers, which require lots of web applications which are tightly integrated into the grid, this type of service is desired to help stabilize APIs and insulate them from core development as much as posible. The Integration Service provides the management facility and some utility services for the external plugins. Several console commands allow management of external repositories and manipulation of plugins. A detailed user-side view for getting started may be seen at: http://bluewallvirtual.com/integration_use. This details the configuration settings in the Robust.ini for the service and gives some instructions for connecting to the example repository. At the moment, there is an implementation of the landtool.php using this, and an example for development. Some other basic plugins are in the development stages and will be released as they are completed.

Criteria

 * Scope: This is already fairly complete and working. It will be good to get more eyes on it and work out details for security and provide hooks for things like Oauth for allowing applications to integrate with external sites to provide rich user experiences with the V3 based viewers. Additional testing and work is required to make the system more reliable at detecting and suggesting upgrades and requirements between versions.


 * Software Requirements: Mono Addins was upgraded to the current version, and and Oauth library was added, however it is not presently being used and is included for future applications.


 * Impact: This work requires no additional modifications to other modules
 * Blockers: None known

Implementation Overview
Integration Service implementation follows standard Robust module design and provides the main code in `OpenSim/Services/Integration` and additional code for external web management applications in `OpenSim/Server/Handlers/Integration`. The services are implemented externally, preferably in the `./addon-modules` area provided for third party development, and are available (in binary form) from repositories subscribed to by the user. A plugin repository for testing is setup at http://bluewallvirtual.com/plugins (please see: http://bluewallvirtual.com/node/46 for instructions and an overview of user interaction in the console). An entry in the Robust.ini allows setting Integration Service to run in development mode, to allow local loading and debugging of plugins under development. Normally this is switched to “false” to have Integration Service manage the plugins via registries. The plugin carries information to direct Integration Service to find initial configuration information that is used in conjunction with the existing Robust configuration. The configuration uses one ini per-plugin and are placed in the location specified in the Robust.ini by the user. Plugins can also cary information for users to aquire additional information and components such as web applications or libraries for use with the plugin. For an overview of plugin development, see the Example at https://github.com/BlueWall/IntegrationExample and also IIntegrationPlugin. Be sure to set DevelopmentMode=true in your Robust.ini to load the plugins in a manner that allows them to be run in your debugger. This needs to be set to false when not developing.

User Experience
Users will use the Robust command line to add repositories and then select plugins from those. The plugins can be enabled, disabled, un-installed from the Robust command line. Information built into the plugin about support sites, etc. can be seen in the command line as well.

A good overview of operation is at http://bluewallvirtual.com/node/46

Low-Level Design
Plugins adhere to an interface that imposes methods to handle startup and unloading. Included in these are methods to provide data needed to set the initial configuration and find the configuration file needed at runtime.

The plugins are managed by the mono-addins framework to allow registration of repositories, listing and selection of available plugins and plugin loading at runtime.