Package com.atlassian.bamboo.capability
Class CapabilityHibernateSetDao
java.lang.Object
org.springframework.dao.support.DaoSupport
org.springframework.orm.hibernate5.support.HibernateDaoSupport
com.atlassian.bamboo.persistence.BambooHibernateObjectDao
com.atlassian.bamboo.capability.CapabilityHibernateSetDao
- All Implemented Interfaces:
bucket.core.persistence.ObjectDao
,CapabilitySetDao
,BambooObjectDao
,org.springframework.beans.factory.InitializingBean
- Direct Known Subclasses:
EphemeralAgentTemplateCapabilitySetHibernateDao
,ImageCapabilitySetHibernateDao
,LocalCapabilityHibernateSetDao
,RemoteCapabilityHibernateSetDao
-
Field Summary
Fields inherited from class org.springframework.dao.support.DaoSupport
logger
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionFinds all the distinct capability keys@NotNull Collection<String>
getAllSystemKeysByType
(@NotNull String type) Returns a list of Capability Keys that match the given type including those for Elastic images.@Nullable ElasticImageConfiguration
getElasticImageConfiguration
(@NotNull CapabilitySet capabilitySet) Finds ElasticImageConfiguration using capability set@Nullable PipelineDefinition
getPipelineDefinition
(@NotNull CapabilitySet capabilitySet) Accessor for getting shared capabilities@NotNull Collection<Capability>
getSystemCapabilities
(String type) Collection ofCapability
which have keys prefixed with system.{type} Used to identify Bamboo system capabilities for Builders / JDKs.@NotNull Collection<Capability>
Collection ofCapability
which have the specified key@NotNull Collection<String>
getSystemKeysExcludingElasticByType
(@NotNull String type) Returns a list of Capability Keys that match the given type but not for capabilities used by Elastic Images.void
saveCapabilitySet
(CapabilitySet capabilitySet) Persist capabilitesMethods inherited from class com.atlassian.bamboo.persistence.BambooHibernateObjectDao
findAll, findAllSorted, findById, findById, refresh, remove, replicate, save, saveRaw, updateModificationData
Methods inherited from class org.springframework.orm.hibernate5.support.HibernateDaoSupport
checkDaoConfig, createHibernateTemplate, currentSession, getHibernateTemplate, getSessionFactory, setHibernateTemplate, setSessionFactory
Methods inherited from class org.springframework.dao.support.DaoSupport
afterPropertiesSet, initDao
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.atlassian.bamboo.persistence.BambooObjectDao
findById
Methods inherited from interface bucket.core.persistence.ObjectDao
findAll, findAllSorted, refresh, remove, replicate, save, saveRaw
-
Constructor Details
-
CapabilityHibernateSetDao
public CapabilityHibernateSetDao()
-
-
Method Details
-
getPersistentClass
- Specified by:
getPersistentClass
in interfacebucket.core.persistence.ObjectDao
-
getPipelineDefinition
@Nullable public @Nullable PipelineDefinition getPipelineDefinition(@NotNull @NotNull CapabilitySet capabilitySet) - Specified by:
getPipelineDefinition
in interfaceCapabilitySetDao
-
getElasticImageConfiguration
@Nullable public @Nullable ElasticImageConfiguration getElasticImageConfiguration(@NotNull @NotNull CapabilitySet capabilitySet) Description copied from interface:CapabilitySetDao
Finds ElasticImageConfiguration using capability set- Specified by:
getElasticImageConfiguration
in interfaceCapabilitySetDao
- Returns:
-
findUniqueCapabilityKeys
Description copied from interface:CapabilitySetDao
Finds all the distinct capability keys- Specified by:
findUniqueCapabilityKeys
in interfaceCapabilitySetDao
- Returns:
-
getSystemCapabilities
Description copied from interface:CapabilitySetDao
Collection ofCapability
which have keys prefixed with system.{type} Used to identify Bamboo system capabilities for Builders / JDKs.- Specified by:
getSystemCapabilities
in interfaceCapabilitySetDao
- Parameters:
type
- eg "builder" or "jdk"- Returns:
- capabilities
-
getSystemKeysExcludingElasticByType
@NotNull public @NotNull Collection<String> getSystemKeysExcludingElasticByType(@NotNull @NotNull String type) Description copied from interface:CapabilitySetDao
Returns a list of Capability Keys that match the given type but not for capabilities used by Elastic Images.- Specified by:
getSystemKeysExcludingElasticByType
in interfaceCapabilitySetDao
- Parameters:
type
- eg "builder" or "jdk"- Returns:
- list of capability keys eg. "system.builder.mvn2.Maven 2"
-
getAllSystemKeysByType
Description copied from interface:CapabilitySetDao
Returns a list of Capability Keys that match the given type including those for Elastic images.- Specified by:
getAllSystemKeysByType
in interfaceCapabilitySetDao
- Parameters:
type
- eg "builder" or "jdk"- Returns:
-
getSystemCapabilitiesByKey
Description copied from interface:CapabilitySetDao
Collection ofCapability
which have the specified key- Specified by:
getSystemCapabilitiesByKey
in interfaceCapabilitySetDao
- Returns:
-
saveCapabilitySet
Description copied from interface:CapabilitySetDao
Persist capabilites- Specified by:
saveCapabilitySet
in interfaceCapabilitySetDao
-