Eric Newcomer wrote:
> Right - another example is asynchronous messaging queuing, like what we're 
 > doing with AMQP, which is becoming more and more important as SOA
 > tends more and more toward loosely-coupled interactions.  In total
 > the industry could really benefit from some better "top down" or
 > "contract first" tooling that defines the service contract first and
 > then allows a choice of implementation.  If you tie the tools to OO,
 > and derive the service from an object, it's more difficult for the SOA
 > to encompass the variety of technologies and "orientations" that exist.

Only when the object doesn't support pluggable transport and invocation layer 
support.  The Jini platform provides this because the use of an object as a
service is first, encapsulated in the Java interface for most uses.  Then,
you have an implementation object.  Finally, that object is made visible to
the world via an Exporter.  An exporter is the point where the deployer gains 
control in how the service object is used by the world.

interface Service extends Remote {
        public List<Items> getItems() throws IOException;
}

public class MyService implements Service {
        Configuration conf;
        public static void main(String args )
                throws IOException, ConfigurationException {
                // Command line arguments indicate where configuration is.
                conf = ConfigurationProvider.getInstance(args);
                Exporter exp = (Exporter)conf.getEntry(
                        MyService.class.getName(),
                        "exporter",
                        Exporter.class,
                        // I can provide a default here
                        new BasicJeriExporter(
                                TcpServerEndpoint.getInstance(0), // Any port
                                new BasicILFactory() // no constraints
                                )
                        );
                // Put this in main so that external classes can create a
                // service for their needs, using their configuration as
                // needed.
                MyService inst = new MyService( conf ); //pass configuration in
                Service svc = (Service)exp.export(inst);
                startService( inst, svc );
        }

        // The service's method
        public List<Items> getItems() {
                ... service method implementation ...
        }

        // sub class can override to change deployment details if Jini
        // deployment is not desired.
        protected static void startService( MyService inst, Service svc ) {
                ... use join manager to deploy ...
        }
}

Now, in the configuration file, one can specify the QOS through the Exporter 
and 
Endpoint use (SSL, TCP, UDP, modbus, semphores, morsecode etc).  Other things 
about the service can be customized, and because the configuration uses live 
objects, I am unlimited in how I may create the configuration values.

Gregg Wonderly




 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/service-orientated-architecture/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to