Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

From the examples-war module, run the class org.spin.examples.Test.  It has a main method that will connect to a Spin node running in a servlet container that's configured to expose the AddQueryAction class from the examples-scala module.

How Spin Loads

...

QueryActions (plug-

...

ins)

When QueryType to QueryAction mappings are declared in node.xml, by default the node will create a single instance of each mapped QueryAction class at startup.  The node looks for QueryAction classes by checking the classloader. If the node is running in a servlet container then it includes the classloader for the servelet container. (Practically, this means that QueryAction implementation classes can be included in .war files) If the system classloader can't find the needed QueryAction implementation class, the Spin plug-in classloader is used. If the same class is found by the system classloader and Spin plug-in classloader, the one found by the system classloader will "win". examples.war already contains needed QueryAction implementations.

...