public class ServiceComponentDesiredStateDAO extends Object
Constructor and Description |
---|
ServiceComponentDesiredStateDAO() |
Modifier and Type | Method and Description |
---|---|
void |
create(ServiceComponentDesiredStateEntity serviceComponentDesiredStateEntity) |
List<ServiceComponentDesiredStateEntity> |
findAll() |
ServiceComponentDesiredStateEntity |
findById(long id)
Gets a
ServiceComponentDesiredStateEntity by its PK ID. |
ServiceComponentDesiredStateEntity |
findByName(long clusterId,
String serviceName,
String componentName)
Finds a
ServiceComponentDesiredStateEntity by a combination of
cluster, service, and component. |
List<ServiceComponentDesiredStateEntity> |
findByNames(Map<Long,Map<String,List<String>>> serviceComponentDesiredStates)
Finds a
ServiceComponentDesiredStateEntity by a combination of cluster id, service and component names. |
ServiceComponentVersionEntity |
findVersion(long clusterId,
String serviceName,
String componentName,
String version)
Gets a specific version for a component
|
List<ServiceComponentVersionEntity> |
findVersions(long clusterId,
String serviceName,
String componentName) |
ServiceComponentDesiredStateEntity |
merge(ServiceComponentDesiredStateEntity serviceComponentDesiredStateEntity) |
void |
refresh(ServiceComponentDesiredStateEntity serviceComponentDesiredStateEntity) |
void |
remove(ServiceComponentDesiredStateEntity serviceComponentDesiredStateEntity) |
void |
removeByName(long clusterId,
String serviceName,
String componentName) |
public ServiceComponentDesiredStateEntity findById(long id)
ServiceComponentDesiredStateEntity
by its PK ID.id
- the ID.null
if it does not exist.public List<ServiceComponentDesiredStateEntity> findAll()
public ServiceComponentDesiredStateEntity findByName(long clusterId, String serviceName, String componentName)
ServiceComponentDesiredStateEntity
by a combination of
cluster, service, and component.clusterId
- the cluster IDserviceName
- the service name (not null
)componentName
- the component name (not null
)public List<ServiceComponentDesiredStateEntity> findByNames(Map<Long,Map<String,List<String>>> serviceComponentDesiredStates)
ServiceComponentDesiredStateEntity
by a combination of cluster id, service and component names.serviceComponentDesiredStates
- - component names mapped by service names and cluster ids.public void refresh(ServiceComponentDesiredStateEntity serviceComponentDesiredStateEntity)
public void create(ServiceComponentDesiredStateEntity serviceComponentDesiredStateEntity)
public ServiceComponentDesiredStateEntity merge(ServiceComponentDesiredStateEntity serviceComponentDesiredStateEntity)
public void remove(ServiceComponentDesiredStateEntity serviceComponentDesiredStateEntity)
public List<ServiceComponentVersionEntity> findVersions(long clusterId, String serviceName, String componentName)
clusterId
- the cluster idserviceName
- the service namecomponentName
- the component namepublic ServiceComponentVersionEntity findVersion(long clusterId, String serviceName, String componentName, String version)
clusterId
- the cluster idserviceName
- the service namecomponentName
- the component nameversion
- the component version to findnull
if not foundCopyright © 2022 Apache Software Foundation. All rights reserved.