|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ow2.petals.system.systemstate.SystemStateServiceImpl
public class SystemStateServiceImpl
Creates and reads state files for components, shared libs and service assemblies. State files are text files that keep the state of JBI entities to allow state retreval after Petals system shutdown or crash.
| Constructor Summary | |
|---|---|
SystemStateServiceImpl()
|
|
| Method Summary | |
|---|---|
org.ow2.petals.systemstate.generated.Component |
createComponentStateHolder(java.lang.String componentName,
java.net.URL installUrl,
java.lang.String archiveName)
Create a Component entry in the System State. |
org.ow2.petals.systemstate.generated.ServiceAssembly |
createServiceAssemblyStateHolder(java.lang.String saName,
java.net.URL installUrl,
java.lang.String archiveName)
Create a ServiceAssembly entry in the System State. |
org.ow2.petals.systemstate.generated.SharedLibrary |
createSharedLibraryStateHolder(java.lang.String slName,
java.lang.String version,
java.net.URL installUrl,
java.lang.String archiveName)
Create a SharedLibrary entry in the System State. |
org.ow2.petals.systemstate.generated.Component |
deleteComponentStateHolder(java.lang.String componentName)
Delete a Component entry from the System State. |
org.ow2.petals.systemstate.generated.ServiceAssembly |
deleteServiceAssemblyStateHolder(java.lang.String saName)
Delete a ServiceAssembly entry from the System State. |
org.ow2.petals.systemstate.generated.SharedLibrary |
deleteSharedLibraryStateHolder(java.lang.String slName,
java.lang.String version)
Delete a SharedLibrary entry from the System State. |
org.ow2.petals.systemstate.generated.Component |
getComponentStateHolder(java.lang.String componentName)
Get the Component entry from the System State. |
java.util.List<org.ow2.petals.systemstate.generated.Component> |
getComponentStateHolders()
Get the Components entries from the System State. |
org.ow2.petals.systemstate.generated.ServiceAssembly |
getServiceAssemblyStateHolder(java.lang.String saName)
Get the ServiceAssembly entry from the System State. |
java.util.List<org.ow2.petals.systemstate.generated.ServiceAssembly> |
getServiceAssemblyStateHolders()
Get the ServiceAssemblys entries from the System State. |
org.ow2.petals.systemstate.generated.SharedLibrary |
getSharedLibraryStateHolder(java.lang.String slName,
java.lang.String version)
Get the SharedLibrary entry from the System State. |
java.util.List<org.ow2.petals.systemstate.generated.SharedLibrary> |
getSharedLibraryStateHolders()
Get the SharedLibrarys entries from the System State. |
java.util.List<org.ow2.petals.systemstate.generated.SharedLibrary> |
getSharedLibraryStateHolders(java.lang.String slName)
Get the SharedLibrarys entries from the System State matching the
given name. |
boolean |
isComponentInstalled(java.lang.String componentName)
Check if the given component is already installed |
protected void |
start()
Initialize the SystemState Service. |
protected void |
stop()
|
void |
updateComponentInstallationState(java.lang.String componentName,
java.lang.String installState)
Update the given component installation state. |
void |
updateComponentLifeCycleState(java.lang.String componentName,
java.lang.String lifecycleState)
Update the given component lifecycle state. |
void |
updateServiceAssemblyState(java.lang.String saName,
java.lang.String lifecycleState)
Update the given service assembly state. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SystemStateServiceImpl()
| Method Detail |
|---|
public org.ow2.petals.systemstate.generated.Component createComponentStateHolder(java.lang.String componentName,
java.net.URL installUrl,
java.lang.String archiveName)
throws ComponentAlreadyExistsException,
org.ow2.petals.systemstate.SystemStateException
SystemStateServiceComponent entry in the System State.
createComponentStateHolder in interface SystemStateServiceComponent entry
org.ow2.petals.systemstate.SystemStateException - failed to persist the new System State
ComponentAlreadyExistsException
public org.ow2.petals.systemstate.generated.ServiceAssembly createServiceAssemblyStateHolder(java.lang.String saName,
java.net.URL installUrl,
java.lang.String archiveName)
throws ServiceAssemblyAlreadyExistsException,
org.ow2.petals.systemstate.SystemStateException
SystemStateServiceServiceAssembly entry in the System State.
createServiceAssemblyStateHolder in interface SystemStateServiceServiceAssembly
org.ow2.petals.systemstate.SystemStateException - failed to persist the new System State
ServiceAssemblyAlreadyExistsException
public org.ow2.petals.systemstate.generated.SharedLibrary createSharedLibraryStateHolder(java.lang.String slName,
java.lang.String version,
java.net.URL installUrl,
java.lang.String archiveName)
throws org.ow2.petals.systemstate.SystemStateException
SystemStateServiceSharedLibrary entry in the System State.
createSharedLibraryStateHolder in interface SystemStateServiceSharedLibrary
org.ow2.petals.systemstate.SystemStateException - failed to persist the new System State
public org.ow2.petals.systemstate.generated.Component deleteComponentStateHolder(java.lang.String componentName)
throws org.ow2.petals.systemstate.SystemStateException
SystemStateServiceComponent entry from the System State.
deleteComponentStateHolder in interface SystemStateServicenull if not found
org.ow2.petals.systemstate.SystemStateException - failed to persist the new System State
public org.ow2.petals.systemstate.generated.ServiceAssembly deleteServiceAssemblyStateHolder(java.lang.String saName)
throws org.ow2.petals.systemstate.SystemStateException
SystemStateServiceServiceAssembly entry from the System State.
deleteServiceAssemblyStateHolder in interface SystemStateServicenull if not found
org.ow2.petals.systemstate.SystemStateException - failed to persist the new System State
public org.ow2.petals.systemstate.generated.SharedLibrary deleteSharedLibraryStateHolder(java.lang.String slName,
java.lang.String version)
throws org.ow2.petals.systemstate.SystemStateException
SystemStateServiceSharedLibrary entry from the System State.
deleteSharedLibraryStateHolder in interface SystemStateServicenull if not found
org.ow2.petals.systemstate.SystemStateException - failed to persist the new System Statepublic org.ow2.petals.systemstate.generated.Component getComponentStateHolder(java.lang.String componentName)
SystemStateServiceComponent entry from the System State.
getComponentStateHolder in interface SystemStateServiceComponent entry or null if not foundpublic java.util.List<org.ow2.petals.systemstate.generated.Component> getComponentStateHolders()
SystemStateServiceComponents entries from the System State.
getComponentStateHolders in interface SystemStateServiceComponents entriespublic org.ow2.petals.systemstate.generated.ServiceAssembly getServiceAssemblyStateHolder(java.lang.String saName)
SystemStateServiceServiceAssembly entry from the System State.
getServiceAssemblyStateHolder in interface SystemStateServiceServiceAssembly entry or null if not foundpublic java.util.List<org.ow2.petals.systemstate.generated.ServiceAssembly> getServiceAssemblyStateHolders()
SystemStateServiceServiceAssemblys entries from the System State.
getServiceAssemblyStateHolders in interface SystemStateServiceServiceAssemblys entries
public org.ow2.petals.systemstate.generated.SharedLibrary getSharedLibraryStateHolder(java.lang.String slName,
java.lang.String version)
SystemStateServiceSharedLibrary entry from the System State.
getSharedLibraryStateHolder in interface SystemStateServiceSharedLibrary entry or null if not foundpublic java.util.List<org.ow2.petals.systemstate.generated.SharedLibrary> getSharedLibraryStateHolders()
SystemStateServiceSharedLibrarys entries from the System State.
getSharedLibraryStateHolders in interface SystemStateServiceSharedLibrarys entriespublic java.util.List<org.ow2.petals.systemstate.generated.SharedLibrary> getSharedLibraryStateHolders(java.lang.String slName)
SystemStateServiceSharedLibrarys entries from the System State matching the
given name.
getSharedLibraryStateHolders in interface SystemStateServiceSharedLibrarys entriespublic boolean isComponentInstalled(java.lang.String componentName)
SystemStateService
isComponentInstalled in interface SystemStateServicetrue if already installed, false otherwise
public void updateComponentInstallationState(java.lang.String componentName,
java.lang.String installState)
throws org.ow2.petals.systemstate.SystemStateException
SystemStateService
updateComponentInstallationState in interface SystemStateServiceorg.ow2.petals.systemstate.SystemStateException
public void updateComponentLifeCycleState(java.lang.String componentName,
java.lang.String lifecycleState)
throws org.ow2.petals.systemstate.SystemStateException
SystemStateService
updateComponentLifeCycleState in interface SystemStateServiceorg.ow2.petals.systemstate.SystemStateException
public void updateServiceAssemblyState(java.lang.String saName,
java.lang.String lifecycleState)
throws org.ow2.petals.systemstate.SystemStateException
SystemStateService
updateServiceAssemblyState in interface SystemStateServiceorg.ow2.petals.systemstate.SystemStateException
protected void start()
throws java.io.IOException,
org.ow2.petals.systemstate.SystemStateException
java.io.IOException
org.ow2.petals.systemstate.SystemStateException
java.net.URISyntaxExceptionprotected void stop()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||