-
Notifications
You must be signed in to change notification settings - Fork 8
Runtime management architecture
For how to use the current implementation of this feature, see Runtime management.
EasySOA needs to allow for the deployment and startup of web services on various application servers, in order to:
- Allow to use FraSCAti Studio as an EasySOA Light runtime, and as the proxy provider for EasySOA ;
- Ease the deployment of web services for application servers, mainly simple, configuration-based systems (such as SoapUI, Bonita...).
It has to allow for users to easily deploy one or several artifacts to the corresponding server, then have start/stop control over the server in question. An additional requirement is to be able to get information about each deployables' dependencies, or even, if possible/relevant, automatically deploy and launch said dependencies on user request.
While we do not have the ambition to support major all major service stacks, the solution aims to be easily extensible by making the architecture pluggable.
- Maven: Maven repositories are a major source of deployable artifacts ; supporting Maven would allow to deploy such artifacts on any compatible application server. A second aspect to handle is the support of POM artifacts as a source of information to retrieve dependencies.
- FraSCAti/FraSCAti Studio: As a part of EasySOA itself, FraSCAti represents a first, major use case for artifact/runtime management, and as such must be a first-class supported stack.
- EasySOA Core Model: By interacting with the EasySOA model, we should be able to retrieve information about deployables (e.g.: thanks to discovery by classpath analysis) and service dependencies, which should additionally allow for a tighter integration with the rest of EasySOA.
- EasySOA Artifact Repository: While it is not specified yet, it is planned to provide a form of technology-agnostic deployable repository within EasySOA (Nuxeo?), in order to make it easier to support non-Maven compatible servers(*)
(*) Some additional servers we could support are SoapUI and BPM engines (Bonita), whose "deployables" are simply configuration files that could easily be stored as documents within the service registry.
The implementation of the runtime management is done with the easysoa-registry-runtime-management project.
The abstract model revolves around the abstract notion of Deployable, meaning a file or set of files that can be deployed and run on an application server. Other entities are:
- Deployable provider: Software capable of storing and providing deployables ;
- Deployable descriptor provider: File or software providing Deployable descriptors, meaning information regarding a deployable and/or its dependencies, at least allowing to retrieve the matching deployable within the Deployable provider ;
- Runtime server: Where deployables are deployed and launched.
Each entity matches one or several interfaces that one needs to implement in order to make it supported by EasySOA.
Here is how some of the technologies we could support match the different concepts:
Maven techs | FraSCAti techs | EasySOA techs | SoapUI techs | Generic | |
---|---|---|---|---|---|
Deployable | Maven artifact | FraSCAti Studio template (TODO) |
SoapUI configuration (TODO) | ||
Deployable Descriptor Provider | Maven repository: POMs | EasySOA Core Model (TODO) | |||
Deployable Provider | Maven repository: JARs |
(FraSCAti Studio tpl. repository?) (TODO) |
EasySOA Repository (TODO) | ||
Deployable Server | FraSCAti [Studio] (TODO) | (Node Light server?) (TODO) | SoapUI mocks server (TODO) | Copy/paste server |
Here is the list of the main interfaces of the abstract model:
DeployableDescriptor Provides information about a deployable
Object getId() // Any ID or hash defining the deployable in a unique way
List getDependencies()
boolean areAllDependenciesKnown() // (*)
DeployableDescriptorProvider Source of information regarding deployables.
DeployableDescriptor fetchDeployableDescriptor(Object id)
Deployable extends DeployableDescriptor Describes a deployable (can be a file or a directory).
InputStream getInputStream() String getName()
DeployableProvider Allows to retrieve deployables
Deployable fetchDeployable(Object id) // (**)
DeployableServer The entry point for EasySOA to control servers. All functionality is contained within embedded services that can be or not supported according to the server type.
String getName() DeploymentService getDeploymentService()
ServerControlService getServerControlService()
EventListenerService getEventListenerService()
DeploymentService Allows to send or remove deployables
boolean deploy(Deployable d) // (**) (***)
boolean remove(Deployable d) // (**) (***)
RuntimeDeployableService Allows to start/stop the server
boolean deploy(Deployable d)
boolean undeploy(Deployable d) boolean start(Deployable d)
boolean stop(Deployable d) List getDeployedDeployables()
RuntimeEventService Empty interface, allows to handle various server events. Example implementation:
boolean addOnDeployListener(OnDeployListener listener)
boolean addOnStartUpListener(OnStartUpListener listener)
- (*) Returns true if we are sure no dependency is missing. Might be false if the Descriptor comes from some incomplete information from the EasySOA model.
- (**) At this point, the implementing class should test the given parameter to make sure the deployable/deployable descriptor is indeed supported.
- (***) The server should, according to its configuration, decide whether to restart at this point the whole server, immediately start the specified deployable (FraSCAti/FraSCAti Studio), etc.
EasySOA uses what is called DeployableControllers to handle the management of deployables. Aimed to be configured by users through the UI, it allows to:
- Specify one (TODO: or more) DeployableProviders ;
- Specify one server ;
- Specify a list of deployables to manage (through their deplyable ID) ;
- ...Then allow to easily control the deployment from the provider(s) to the server.
While DeployableControllers can be used programmatically, they are primarily used within EasySOA, combined with extension points to provide an easy way to define servers & providers that can be used through the EasySOA UI. For more information, see Runtime management.
-
Deployable
- MavenArtifact
- FraSCAtiStudioTemplate
- SoapUIConfiguration
- BonitaWorkflow
-
DeployableDescriptorProvider
- MavenPOM
(provides one MavenArtifactDescriptor)
- MavenApplicationPOM
(provides all MavenArtifactDescriptors from all child modules)
- EasySOAModelAPI
(allows to retrieve various types of DeployableDescriptors)
- MavenPOM
-
DeployableProvider
- MavenRepository
(retrieves MavenArtifacts)
- FraSCAtiStudioTemplateRespository
(retrieves FraSCAtiStudioTemplates)
- EasySOARepository
(retrieves SoapUIConfigurations & BonitaWorkflows)
- MavenRepository
-
DeployableServer
- AbstractFraSCAtiServer
- LocalFraSCAtiServer
- RemoteFraSCAtiServer
- SoapUIServer
(always local)
- AbstractBonitaServer
- LocalBonitaServer
- RemoteBonitaServer
- AbstractCopyPasteServer
(with some configuration, is enough to support deployment to Tomcat for instance)
- AbstractFraSCAtiServer