couchdb

package
v2.5.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 9, 2024 License: MPL-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckAndCreateDB

func CheckAndCreateDB(client *kivik.Client, db string) error

func CreateCouchDBConnection

func CreateCouchDBConnection(logger *logrus.Entry, cfg config.CouchDBPSEConfig) (*kivik.Client, error)

func NewCouchCARepository

func NewCouchCARepository(client *kivik.Client) (storage.CACertificatesRepo, error)

func NewCouchCertificateRepository

func NewCouchCertificateRepository(client *kivik.Client) (storage.CertificatesRepo, error)

func NewCouchDMSRepository

func NewCouchDMSRepository(client *kivik.Client) (storage.DMSRepo, error)

func NewCouchDeviceRepository

func NewCouchDeviceRepository(client *kivik.Client) (storage.DeviceManagerRepo, error)

Types

type CouchDBCAStorage

type CouchDBCAStorage struct {
	// contains filtered or unexported fields
}

func (*CouchDBCAStorage) Count

func (db *CouchDBCAStorage) Count(ctx context.Context) (int, error)

func (*CouchDBCAStorage) CountByEngine

func (db *CouchDBCAStorage) CountByEngine(ctx context.Context, engineID string) (int, error)

func (*CouchDBCAStorage) CountByStatus

func (db *CouchDBCAStorage) CountByStatus(ctx context.Context, status models.CertificateStatus) (int, error)

func (*CouchDBCAStorage) Delete

func (db *CouchDBCAStorage) Delete(ctx context.Context, id string) error

func (*CouchDBCAStorage) Insert

func (db *CouchDBCAStorage) Insert(ctx context.Context, caCertificate *models.CACertificate) (*models.CACertificate, error)

func (*CouchDBCAStorage) SelectAll

func (*CouchDBCAStorage) SelectByCommonName

func (db *CouchDBCAStorage) SelectByCommonName(ctx context.Context, commonName string, req storage.StorageListRequest[models.CACertificate]) (string, error)

func (*CouchDBCAStorage) SelectByParentCA

func (db *CouchDBCAStorage) SelectByParentCA(ctx context.Context, parentCAID string, req storage.StorageListRequest[models.CACertificate]) (string, error)

func (*CouchDBCAStorage) SelectByType

func (*CouchDBCAStorage) SelectExistsByID

func (db *CouchDBCAStorage) SelectExistsByID(ctx context.Context, id string) (bool, *models.CACertificate, error)

func (*CouchDBCAStorage) SelectExistsBySerialNumber

func (db *CouchDBCAStorage) SelectExistsBySerialNumber(ctx context.Context, serialNumber string) (bool, *models.CACertificate, error)

func (*CouchDBCAStorage) Update

func (db *CouchDBCAStorage) Update(ctx context.Context, caCertificate *models.CACertificate) (*models.CACertificate, error)

type CouchDBCertificateStorage

type CouchDBCertificateStorage struct {
	// contains filtered or unexported fields
}

func (*CouchDBCertificateStorage) Count

func (*CouchDBCertificateStorage) CountByCA

func (db *CouchDBCertificateStorage) CountByCA(ctx context.Context, caID string) (int, error)

func (*CouchDBCertificateStorage) CountByCAIDAndStatus

func (db *CouchDBCertificateStorage) CountByCAIDAndStatus(ctx context.Context, caID string, status models.CertificateStatus) (int, error)

func (*CouchDBCertificateStorage) Insert

func (*CouchDBCertificateStorage) SelectAll

func (*CouchDBCertificateStorage) SelectByCA

func (*CouchDBCertificateStorage) SelectByCAIDAndStatus

func (*CouchDBCertificateStorage) SelectByExpirationDate

func (db *CouchDBCertificateStorage) SelectByExpirationDate(ctx context.Context, beforeExpirationDate time.Time, afterExpirationDate time.Time, req storage.StorageListRequest[models.Certificate]) (string, error)

func (*CouchDBCertificateStorage) SelectByParentCA

func (*CouchDBCertificateStorage) SelectByStatus

func (*CouchDBCertificateStorage) SelectByType

func (*CouchDBCertificateStorage) SelectExistsBySerialNumber

func (db *CouchDBCertificateStorage) SelectExistsBySerialNumber(ctx context.Context, id string) (bool, *models.Certificate, error)

func (*CouchDBCertificateStorage) Update

type CouchDBDMSStorage

type CouchDBDMSStorage struct {
	// contains filtered or unexported fields
}

func (*CouchDBDMSStorage) Count

func (db *CouchDBDMSStorage) Count(ctx context.Context) (int, error)

func (*CouchDBDMSStorage) Insert

func (db *CouchDBDMSStorage) Insert(ctx context.Context, dms *models.DMS) (*models.DMS, error)

func (*CouchDBDMSStorage) SelectAll

func (db *CouchDBDMSStorage) SelectAll(ctx context.Context, exhaustiveRun bool, applyFunc func(models.DMS), queryParams *resources.QueryParameters, extraOpts map[string]interface{}) (string, error)

func (*CouchDBDMSStorage) SelectExists

func (db *CouchDBDMSStorage) SelectExists(ctx context.Context, ID string) (bool, *models.DMS, error)

func (*CouchDBDMSStorage) Update

func (db *CouchDBDMSStorage) Update(ctx context.Context, dms *models.DMS) (*models.DMS, error)

type CouchDBDeviceStorage

type CouchDBDeviceStorage struct {
	// contains filtered or unexported fields
}

func (*CouchDBDeviceStorage) Count

func (db *CouchDBDeviceStorage) Count(ctx context.Context) (int, error)

func (*CouchDBDeviceStorage) CountByStatus

func (db *CouchDBDeviceStorage) CountByStatus(ctx context.Context, status models.DeviceStatus) (int, error)

func (*CouchDBDeviceStorage) Insert

func (db *CouchDBDeviceStorage) Insert(ctx context.Context, device *models.Device) (*models.Device, error)

func (*CouchDBDeviceStorage) SelectAll

func (db *CouchDBDeviceStorage) SelectAll(ctx context.Context, exhaustiveRun bool, applyFunc func(models.Device), queryParams *resources.QueryParameters, extraOpts map[string]interface{}) (string, error)

func (*CouchDBDeviceStorage) SelectByDMS

func (db *CouchDBDeviceStorage) SelectByDMS(ctx context.Context, dmsID string, exhaustiveRun bool, applyFunc func(models.Device), queryParams *resources.QueryParameters, extraOpts map[string]interface{}) (string, error)

func (*CouchDBDeviceStorage) SelectExists

func (db *CouchDBDeviceStorage) SelectExists(ctx context.Context, ID string) (bool, *models.Device, error)

func (*CouchDBDeviceStorage) Update

func (db *CouchDBDeviceStorage) Update(ctx context.Context, device *models.Device) (*models.Device, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL