Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( CertSubjectMappingLoaderCorrelationID = "cert-subject-mapping-loader-correlation-id" CertSubjectMappingInitialLoaderCorrelationID = "cert-subject-mapping-initial-loader-correlation-id" CertSubjectMappingRetryInterval = 50 * time.Millisecond )
Functions ¶
func NewCertSubjectMappingCache ¶
func NewCertSubjectMappingCache() *certSubjectMappingCache
NewCertSubjectMappingCache creates a new certificate subject mapping cache
Types ¶
type Cache ¶
type Cache interface { Get() []csm.SubjectConsumerTypeMapping Put(certSubjectMappings []csm.SubjectConsumerTypeMapping) }
Cache is responsible for the read and write operation of the cert subject mapping in-memory storage
type DirectorClient ¶
type DirectorClient interface {
ListCertificateSubjectMappings(ctx context.Context, after string) (*schema.CertificateSubjectMappingPage, error)
}
DirectorClient is a GraphQL client used to communicate with the director component and the DB
type Loader ¶
type Loader interface { Run(ctx context.Context, certSubjectMappingsFromEnv string) InitialiseCertSubjectMappings(ctx context.Context, certSubjectMappingsFromEnv string) error }
Loader provide mechanism to load certificate subject mappings' data into in-memory storage
func NewCertSubjectMappingLoader ¶
func NewCertSubjectMappingLoader(certSubjectMappingCache *certSubjectMappingCache, certSubjectMappingCfg Config, directorClient DirectorClient) Loader
Click to show internal directories.
Click to hide internal directories.