easysoa / EasySOA

A light, collaborative platform to make Service Oriented Architecture simple.
http://www.easysoa.org
35 stars 8 forks source link

Discovery by parsing : Hook in FraSCAti to detect a composite start in a standalone FraSCAti #70

Open JGuillemotte opened 12 years ago

JGuillemotte commented 12 years ago

See Discovery by SCA parsing issue : https://github.com/easysoa/EasySOA/issues/28

FraSCAti Hook Issue :

Currently, the SCA import works only with a composite file specified in the SCA import Nuxeo page. We want to integrate more the smarttravel trip sample in the demo, especially to discover services when a sample is started in FraSCAti.

In the current demo release (0.3), the smarttravel trip sample is started in an external FraSCAti engine. As the SCA import works in an Nuxeo embeded FraSCAti engine, it is not possible to make a deeper integration.

Here we have 2 Solutions :

Use an Nuxeo embeded FraSCAti and start the sample in this engine : this solution can be used in a development platform or for a short term solution. or still use an external FraSCAti engine and add a hook to plug custom features on the composite processing cycle. Good solution in situations where a Frascati engine is not on the same platform that Nuxeo.

The solution could be to add a hook in FraSCAti : This hook could work with a 'LifeCycleListener' interface which defines a 'handle' method with 2 parameters : the processing mode and the processing context. To indicate if FraSCAti have to send events to a lifecycle listener, we can use a parameter in the FraSCAti launch command.

For the next release of the demo, if we have FraSCAti works in Nuxeo, we could start the smarttravel sample in the Frascati Nuxeo embeded.

JGuillemotte commented 12 years ago

Solution proposed by C. Munilla :

Put a discovery hook solution based on a intent.

How it work :

The Parse-intent is linked programmatically to the SCA Parser in the FraSCAtiServiceItf class.

Limitations :

See https://github.com/easysoa/EasySOA/blob/master/easysoa-registry/nuxeo-frascati/src/main/java/org/nuxeo/frascati/NuxeoFraSCAti.java

Both limitations can be solved by weaving in other intents. We will choose the way and do it once all functional requirements & business uses are known, see #79 (& #21) .