com.projectdarkstar.tools.dtc.service
Interface ConfigAppsService


public interface ConfigAppsService

This interface exposes operations that allow creating, updating, and deleting configurations for the client, server, and system probe applications. It is intended to be a remote interface exposing a stateless session EJB3.0 bean.


Method Summary
 Long addClientApp(ClientAppDTO clientApp)
          Add a ClientApp to persistent storage based on the given clientApp.
 Long addClientAppConfig(ClientAppConfigDTO clientAppConfig)
          Add a ClientAppConfig to persistent storage based on the given clientAppConfig.
 Long addServerApp(ServerAppDTO serverApp)
          Add a ServerApp object based on the given serverApp to persistent storage.
 Long addServerAppConfig(ServerAppConfigDTO serverAppConfig)
          Add a ServerAppConfig object based on the given serverAppConfig to persistent storage.
 Long addSystemProbe(SystemProbeDTO systemProbe, String tags)
          Add a SystemProbe to persistent storage based on the given systemProbe.
 void deleteClientApp(Long id)
          Remove the ClientApp with the given id from persistent storage.
 void deleteClientAppConfig(Long id)
          Remove the ClientAppConfig with the given id from persistent storage.
 void deleteServerApp(Long id)
          Remove the ServerApp with the given id from persistent storage.
 void deleteServerAppConfig(Long id)
          Remove the ServerAppConfig with the given id from persistent storage.
 void deleteSystemProbe(Long id)
          Remove the SystemProbe with the given id from persistent storage.
 void updateClientApp(Long id, Map<String,Object> updates)
          Update the ClientApp with the given id.
 void updateClientAppConfig(Long id, Map<String,Object> updates)
          Update the ClientAppConfig with the given id.
 void updateServerApp(Long id, Map<String,Object> updates)
          Update the ServerApp in storage with the given id.
 void updateServerAppConfig(Long id, Map<String,Object> updates)
          Update the ServerAppConfig in storage with the given id.
 void updateSystemProbe(Long id, Map<String,Object> updates)
          Update the SystemProbe with the given id in persistent storage.
 

Method Detail

addServerApp

Long addServerApp(ServerAppDTO serverApp)
                  throws DTCServiceException
Add a ServerApp object based on the given serverApp to persistent storage. If the given serverApp's pkgLibrary field is set, this method will create a new PkgLibrary if it does not already exist in the database. Otherwise, it will set the pkgLibrary reference to the PkgLibrary in the database with the already existing id. Additionally, this method will always create a ServerApp object that contains an empty list of configs. The configs attribute of the given serverApp will be ignored if it has any objects in it.

Parameters:
serverApp - the serverApp to add
Returns:
id of the newly created ServerApp object
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

addServerAppConfig

Long addServerAppConfig(ServerAppConfigDTO serverAppConfig)
                        throws DTCServiceException
Add a ServerAppConfig object based on the given serverAppConfig to persistent storage.

Parameters:
serverAppConfig - the serverAppConfig to add
Returns:
id of the newly created ServerAppConfig object
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

updateServerApp

void updateServerApp(Long id,
                     Map<String,Object> updates)
                     throws DTCServiceException
Update the ServerApp in storage with the given id. The given Map of updates maps bean attribute names to values to be used for the updates.

Parameters:
id - id of the ServerApp to update
updates - map of updates to use to update the ServerApp
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

updateServerAppConfig

void updateServerAppConfig(Long id,
                           Map<String,Object> updates)
                           throws DTCServiceException
Update the ServerAppConfig in storage with the given id. The given Map of updates maps bean attribute names to values to be used for the updates.

Parameters:
id - id of the ServerAppConfig to update
updates - map of updates to use to update the ServerAppConfig
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

deleteServerApp

void deleteServerApp(Long id)
                     throws DTCServiceException
Remove the ServerApp with the given id from persistent storage.

Parameters:
id - id of the ServerApp to update
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

deleteServerAppConfig

void deleteServerAppConfig(Long id)
                           throws DTCServiceException
Remove the ServerAppConfig with the given id from persistent storage.

Parameters:
id - id of the ServerAppConfig to update
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

addClientApp

Long addClientApp(ClientAppDTO clientApp)
                  throws DTCServiceException
Add a ClientApp to persistent storage based on the given clientApp. If the given clientApp's pkgLibrary field is set, this method will create a new PkgLibrary if it does not already exist in the database. Otherwise, it will set the pkgLibrary reference to the PkgLibrary in the database with the already existing id. Additionally, this method will always create a ClientApp object that contains an empty list of configs. The configs attribute of the given clientApp will be ignored if it has any objects in it.

Parameters:
clientApp - clientApp to add
Returns:
id of the newly created ClientApp
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

addClientAppConfig

Long addClientAppConfig(ClientAppConfigDTO clientAppConfig)
                        throws DTCServiceException
Add a ClientAppConfig to persistent storage based on the given clientAppConfig.

Parameters:
clientAppConfig - clientAppConfig to add
Returns:
id of the newly created ClientAppConfig
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

updateClientApp

void updateClientApp(Long id,
                     Map<String,Object> updates)
                     throws DTCServiceException
Update the ClientApp with the given id. The given Map of updates maps bean attribute names to values to be used for the updates.

Parameters:
id - id of the ClientApp to update
updates - map of updates to be used to update the ClientApp
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

updateClientAppConfig

void updateClientAppConfig(Long id,
                           Map<String,Object> updates)
                           throws DTCServiceException
Update the ClientAppConfig with the given id. The given Map of updates maps bean attribute names to values to be used for the updates.

Parameters:
id - id of the ClientAppConfig to update
updates - map of updates to be used to update the ClientAppConfig
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

deleteClientApp

void deleteClientApp(Long id)
                     throws DTCServiceException
Remove the ClientApp with the given id from persistent storage.

Parameters:
id - id of the ClientApp to remove
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

deleteClientAppConfig

void deleteClientAppConfig(Long id)
                           throws DTCServiceException
Remove the ClientAppConfig with the given id from persistent storage.

Parameters:
id - id of the ClientAppConfig to remove
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

addSystemProbe

Long addSystemProbe(SystemProbeDTO systemProbe,
                    String tags)
                    throws DTCServiceException
Add a SystemProbe to persistent storage based on the given systemProbe. The comma and/or space separated string of tags is to be used to assign the new SystemProbe to a set of SystemProbeTag entities. For each tag, a new SystemProbeTag will be created or an existing tag entity with the same name will be used.

Parameters:
systemProbe - systemProbe to add
tags - comma and/or space separated list of tags
Returns:
id of the newly created SystemProbe
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

updateSystemProbe

void updateSystemProbe(Long id,
                       Map<String,Object> updates)
                       throws DTCServiceException
Update the SystemProbe with the given id in persistent storage. The given Map of updates maps bean attribute names to values to be used for the updates.

Parameters:
id - id of the SystemProbe to update
updates - map of updates to be used to update the SystemProbe
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException

deleteSystemProbe

void deleteSystemProbe(Long id)
                       throws DTCServiceException
Remove the SystemProbe with the given id from persistent storage.

Parameters:
id - id of the SystemProbe to remove
Throws:
com.projectdarkstar.tools.dtc.service.DTCServiceException
DTCServiceException


Copyright © 2013. All Rights Reserved.