WxService

From OpenSimulator

(Difference between revisions)
Jump to: navigation, search
Line 1: Line 1:
== status ==
+
== WxService, an example module for Robust ==
'''This will not be going to core or developed any further because a middleware layer is not necessary for Robust. I will be polishing up the https code so we can use it for connectors. And I will add a tutorial that uses the user handler example code as a Robust shell in the next few days April 27, 2011.'''
+
WxService is a user-space module consisting of a set of connector, service and handler for Robust. It provides a starting point and example for writing modules to run in the Robust server shell. The example framework demonstrates...
 +
*the steps needed to configure and load the application under the Robust server
 +
*servicing requests that interact with existing core OpenSim services
 +
*adding commands to the Robust console
 +
*adding a custom database with migrations
 +
*building an application under Robust
  
An add-on set of services provided by BlueWall. WxServices is in the WxService branch of the OpenSimulator git repo.
+
The purpose of WxService is to show how one can leverage the Robust shell to provide points of interaction with OpenSim core for external applications. This gives anyone an opportunity to build applications that can interact with OpenSim without manipulating the databases directly (bad, bad, bad). It also allows applications that have traditionally used in external apache/php services to be more tightly integrated into the OpenSim framework. It should make distribution of modules to users simpler by using the OpenSim database facilities to migrate data on installations or upgrades. And, the applications can be made better by providing management commands in the console.  
 
+
For a description and quick tour of some example code to exercise it see http://bluewallvirtual.com/WxService
+
 
+
BlueWall's introductory notes from his blog on 17-Apr-2011 follow:
+
 
+
In the past, web interfaces and other external applications have been built to manipulate the OpenSimulator data directly. Recent web interfaces and applications are still being developed using these same techniques, but it is arguable whether whether this is a best practice. I don't believe that allowing a host of applications direct access to my data is a good practice at all, so I have been developing WxServices for OpenSimulator.
+
 
+
WxService is a Robust service that provides a framework for developing secure middleware connectors. The service exposes an interface that allows handlers to be developed in the addon-module directory, along with other end-user developed code. Then manages them in a way similar to the way the Robust handler components are managed. The user provided connectors implement handlers that allow external applications such as web interfaces and management systems to securely and reliably work with the OpenSim internal resources. And, by providing the mechanism to allow the POST handlers for the service to reside outside the core development tree allows easier distribution and integration for third party developers to share code with other users in the same way that region modules can be shared now. Also, an optional https server is enabled to secure the traffic between the application and the service.
+
 
+
 
+
='''Getting the code:'''=
+
 
+
=='''From the OpenSimulator git repo...'''==
+
The WxService is presently in a branch of the OpenSim repo. Your clone of the repo has the links back to the WxService branch inside and you will need to do a couple of steps to checkout the branch into your local copy.
+
 
+
* '''checking out the branch''' If you refresh your copy with '''"git pull"''', then look at your branches with '''"git branch -a"''', you should see ''"remotes/origin/WxService"'' in the list. You can get the branch into your repo by using '''"git checkout -b LocalName origin/WxService"''' ''where LocalName is replaced with the name you want to call your branch''. Have a look in your repo at ''./OpenSim/Services'' where you should see the WxService directory. And, '''"git branch"''' should show you sitting in whatever you named your local branch. You can always switch between your branches with the '''"git checkout"''' command.
+
 
+
* '''updating the branch''' When updates are available, you may get them into your local copy. Just do a '''"git branch"''' to see if you have the WxService branch checked out in your working copy. Then do '''"git pull origin WxService"''' to update your local copy.
+
 
+
* '''keeping things clean''' Be sure to watch for remnants of the builds when updating or switching branches. You can use '''"xbuild /t:clean''' to remove the build objects and dlls. Follow with '''"mono ./bin/Prebuild.exe /clean"''' to remove the generated project files, then use '''"git reset --hard HEAD"''' to put back a couple of things that Prebuild removes. Now, you will be able to do updates or switch branches without having to worry about getting conflicts in your builds.
+
 
+
=='''From Github...'''==
+
You can get to the WxService branch on github at https://github.com/BlueWall/opensim/tree/WxService . From there you can fork that repo, clone it or download the source in zip or tar.gz formats.
+
  
 
=='''Example code'''==
 
=='''Example code'''==
You can get a copy of the example code to exercise WxService at http://bluewallvirtual.com/sites/bluewallvirtual.com/files/WxService-Example.tar_.bz2 .
+
The code is laid out in directories similar to the core services and connectors in OpenSim core and is heavily commented. It should be pretty easy to follow and adapt to your own projects. See: http://bluewallvirtual.com/WxService_Reloaded for code and discussion forum. For help, post in the forum there (no account required) or find me (BlueWall) on IRC - Freenode #opensim

Revision as of 05:01, 25 May 2011

WxService, an example module for Robust

WxService is a user-space module consisting of a set of connector, service and handler for Robust. It provides a starting point and example for writing modules to run in the Robust server shell. The example framework demonstrates...

  • the steps needed to configure and load the application under the Robust server
  • servicing requests that interact with existing core OpenSim services
  • adding commands to the Robust console
  • adding a custom database with migrations
  • building an application under Robust

The purpose of WxService is to show how one can leverage the Robust shell to provide points of interaction with OpenSim core for external applications. This gives anyone an opportunity to build applications that can interact with OpenSim without manipulating the databases directly (bad, bad, bad). It also allows applications that have traditionally used in external apache/php services to be more tightly integrated into the OpenSim framework. It should make distribution of modules to users simpler by using the OpenSim database facilities to migrate data on installations or upgrades. And, the applications can be made better by providing management commands in the console.

Example code

The code is laid out in directories similar to the core services and connectors in OpenSim core and is heavily commented. It should be pretty easy to follow and adapt to your own projects. See: http://bluewallvirtual.com/WxService_Reloaded for code and discussion forum. For help, post in the forum there (no account required) or find me (BlueWall) on IRC - Freenode #opensim

Personal tools
General
About This Wiki