Documentation
¶
Index ¶
- type PostgresDB
- func (db *PostgresDB) BulkDeleteObjects(ctx context.Context, ids []string) error
- func (db *PostgresDB) BulkUpdateAccessMethods(ctx context.Context, updates map[string][]drs.AccessMethod) error
- func (db *PostgresDB) CreateBucketScope(ctx context.Context, scope *core.BucketScope) error
- func (db *PostgresDB) CreateObject(ctx context.Context, obj *core.InternalObject) error
- func (db *PostgresDB) CreateObjectAlias(ctx context.Context, aliasID, canonicalObjectID string) error
- func (db *PostgresDB) DeleteObject(ctx context.Context, id string) error
- func (db *PostgresDB) DeleteS3Credential(ctx context.Context, bucket string) error
- func (db *PostgresDB) GetBucketScope(ctx context.Context, organization, projectID string) (*core.BucketScope, error)
- func (db *PostgresDB) GetBulkObjects(ctx context.Context, ids []string) ([]core.InternalObject, error)
- func (db *PostgresDB) GetFileUsage(ctx context.Context, objectID string) (*core.FileUsage, error)
- func (db *PostgresDB) GetFileUsageSummary(ctx context.Context, inactiveSince *time.Time) (core.FileUsageSummary, error)
- func (db *PostgresDB) GetObject(ctx context.Context, id string) (*core.InternalObject, error)
- func (db *PostgresDB) GetObjectsByChecksum(ctx context.Context, checksum string) ([]core.InternalObject, error)
- func (db *PostgresDB) GetObjectsByChecksums(ctx context.Context, checksums []string) (map[string][]core.InternalObject, error)
- func (db *PostgresDB) GetPendingLFSMeta(ctx context.Context, oid string) (*core.PendingLFSMeta, error)
- func (db *PostgresDB) GetS3Credential(ctx context.Context, bucket string) (*core.S3Credential, error)
- func (db *PostgresDB) GetServiceInfo(ctx context.Context) (*drs.Service, error)
- func (db *PostgresDB) ListBucketScopes(ctx context.Context) ([]core.BucketScope, error)
- func (db *PostgresDB) ListFileUsage(ctx context.Context, limit, offset int, inactiveSince *time.Time) ([]core.FileUsage, error)
- func (db *PostgresDB) ListObjectIDsByResourcePrefix(ctx context.Context, resourcePrefix string) ([]string, error)
- func (db *PostgresDB) ListS3Credentials(ctx context.Context) ([]core.S3Credential, error)
- func (db *PostgresDB) PopPendingLFSMeta(ctx context.Context, oid string) (*core.PendingLFSMeta, error)
- func (db *PostgresDB) RecordFileDownload(ctx context.Context, objectID string) error
- func (db *PostgresDB) RecordFileUpload(ctx context.Context, objectID string) error
- func (db *PostgresDB) RegisterObjects(ctx context.Context, objects []core.InternalObject) error
- func (db *PostgresDB) ResolveObjectAlias(ctx context.Context, aliasID string) (string, error)
- func (db *PostgresDB) SavePendingLFSMeta(ctx context.Context, entries []core.PendingLFSMeta) error
- func (db *PostgresDB) SaveS3Credential(ctx context.Context, cred *core.S3Credential) error
- func (db *PostgresDB) UpdateObjectAccessMethods(ctx context.Context, objectID string, accessMethods []drs.AccessMethod) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PostgresDB ¶
type PostgresDB struct {
// contains filtered or unexported fields
}
func NewPostgresDB ¶
func NewPostgresDB(dsn string) (*PostgresDB, error)
func (*PostgresDB) BulkDeleteObjects ¶
func (db *PostgresDB) BulkDeleteObjects(ctx context.Context, ids []string) error
func (*PostgresDB) BulkUpdateAccessMethods ¶
func (db *PostgresDB) BulkUpdateAccessMethods(ctx context.Context, updates map[string][]drs.AccessMethod) error
func (*PostgresDB) CreateBucketScope ¶
func (db *PostgresDB) CreateBucketScope(ctx context.Context, scope *core.BucketScope) error
func (*PostgresDB) CreateObject ¶
func (db *PostgresDB) CreateObject(ctx context.Context, obj *core.InternalObject) error
func (*PostgresDB) CreateObjectAlias ¶
func (db *PostgresDB) CreateObjectAlias(ctx context.Context, aliasID, canonicalObjectID string) error
func (*PostgresDB) DeleteObject ¶
func (db *PostgresDB) DeleteObject(ctx context.Context, id string) error
func (*PostgresDB) DeleteS3Credential ¶
func (db *PostgresDB) DeleteS3Credential(ctx context.Context, bucket string) error
func (*PostgresDB) GetBucketScope ¶
func (db *PostgresDB) GetBucketScope(ctx context.Context, organization, projectID string) (*core.BucketScope, error)
func (*PostgresDB) GetBulkObjects ¶
func (db *PostgresDB) GetBulkObjects(ctx context.Context, ids []string) ([]core.InternalObject, error)
func (*PostgresDB) GetFileUsage ¶
func (*PostgresDB) GetFileUsageSummary ¶
func (db *PostgresDB) GetFileUsageSummary(ctx context.Context, inactiveSince *time.Time) (core.FileUsageSummary, error)
func (*PostgresDB) GetObject ¶
func (db *PostgresDB) GetObject(ctx context.Context, id string) (*core.InternalObject, error)
func (*PostgresDB) GetObjectsByChecksum ¶
func (db *PostgresDB) GetObjectsByChecksum(ctx context.Context, checksum string) ([]core.InternalObject, error)
func (*PostgresDB) GetObjectsByChecksums ¶
func (db *PostgresDB) GetObjectsByChecksums(ctx context.Context, checksums []string) (map[string][]core.InternalObject, error)
func (*PostgresDB) GetPendingLFSMeta ¶
func (db *PostgresDB) GetPendingLFSMeta(ctx context.Context, oid string) (*core.PendingLFSMeta, error)
func (*PostgresDB) GetS3Credential ¶
func (db *PostgresDB) GetS3Credential(ctx context.Context, bucket string) (*core.S3Credential, error)
func (*PostgresDB) GetServiceInfo ¶
func (*PostgresDB) ListBucketScopes ¶
func (db *PostgresDB) ListBucketScopes(ctx context.Context) ([]core.BucketScope, error)
func (*PostgresDB) ListFileUsage ¶
func (*PostgresDB) ListObjectIDsByResourcePrefix ¶
func (*PostgresDB) ListS3Credentials ¶
func (db *PostgresDB) ListS3Credentials(ctx context.Context) ([]core.S3Credential, error)
func (*PostgresDB) PopPendingLFSMeta ¶
func (db *PostgresDB) PopPendingLFSMeta(ctx context.Context, oid string) (*core.PendingLFSMeta, error)
func (*PostgresDB) RecordFileDownload ¶
func (db *PostgresDB) RecordFileDownload(ctx context.Context, objectID string) error
func (*PostgresDB) RecordFileUpload ¶
func (db *PostgresDB) RecordFileUpload(ctx context.Context, objectID string) error
func (*PostgresDB) RegisterObjects ¶
func (db *PostgresDB) RegisterObjects(ctx context.Context, objects []core.InternalObject) error
func (*PostgresDB) ResolveObjectAlias ¶
func (*PostgresDB) SavePendingLFSMeta ¶
func (db *PostgresDB) SavePendingLFSMeta(ctx context.Context, entries []core.PendingLFSMeta) error
func (*PostgresDB) SaveS3Credential ¶
func (db *PostgresDB) SaveS3Credential(ctx context.Context, cred *core.S3Credential) error
func (*PostgresDB) UpdateObjectAccessMethods ¶
func (db *PostgresDB) UpdateObjectAccessMethods(ctx context.Context, objectID string, accessMethods []drs.AccessMethod) error
Click to show internal directories.
Click to hide internal directories.