WxService

From OpenSimulator

Revision as of 17:39, 27 April 2011 by BlueWall (Talk | contribs)

Jump to: navigation, search

Contents

status

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.

An add-on set of services provided by BlueWall. WxServices is in the WxService branch of the OpenSimulator git repo.

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

You can get a copy of the example code to exercise WxService at http://bluewallvirtual.com/sites/bluewallvirtual.com/files/WxService-Example.tar_.bz2 .

Personal tools
General
About This Wiki