Class StableServiceVersionResolver
- java.lang.Object
-
- org.openstack4j.model.common.resolvers.StableServiceVersionResolver
-
- All Implemented Interfaces:
ServiceVersionResolver
public final class StableServiceVersionResolver extends Object implements ServiceVersionResolver
Resolves each service to the lowest version which we consider most stable and tested- Author:
- Jeremy Unruh
-
-
Field Summary
Fields Modifier and Type Field Description static StableServiceVersionResolverINSTANCE
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Access.ServiceresolveV2(ServiceType type, SortedSet<? extends Access.Service> services)Resolves to a single identity v2 service for the givenServiceTypeand set of associatedservices.ServiceresolveV3(ServiceType type, SortedSet<? extends Service> services)Resolves to a single identity v3 service for the givenServiceTypeand set of associatedservices.
-
-
-
Field Detail
-
INSTANCE
public static final StableServiceVersionResolver INSTANCE
-
-
Method Detail
-
resolveV3
public Service resolveV3(ServiceType type, SortedSet<? extends Service> services)
Description copied from interface:ServiceVersionResolverResolves to a single identity v3 service for the givenServiceTypeand set of associatedservices.For example if a deployment contains Compute/Nova version 2 and 2.1 then resolve would be invoked with the params of
ServiceType.COMPUTEand a set of 2 services (Compute 2 and Compute 2.1). The resolver is responsible for picking the appropriate version- Specified by:
resolveV3in interfaceServiceVersionResolver- Parameters:
type- the type ofservicesservices- the sorted by version set of service(s)- Returns:
- a single service
-
resolveV2
public Access.Service resolveV2(ServiceType type, SortedSet<? extends Access.Service> services)
Description copied from interface:ServiceVersionResolverResolves to a single identity v2 service for the givenServiceTypeand set of associatedservices.For example if a deployment contains Compute/Nova version 2 and 2.1 then resolve would be invoked with the params of
ServiceType.COMPUTEand a set of 2 services (Compute 2 and Compute 2.1). The resolver is responsible for picking the appropriate version- Specified by:
resolveV2in interfaceServiceVersionResolver- Parameters:
type- type the type ofservicesservices- the sorted by version set of service(s)- Returns:
- a single service
-
-