pgstore

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2026 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PgAttachmentStore

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

func (*PgAttachmentStore) Delete

func (s *PgAttachmentStore) Delete(ctx context.Context, storageKey string) error

func (*PgAttachmentStore) GetSignedURL

func (s *PgAttachmentStore) GetSignedURL(_ context.Context, _ string, _ time.Duration) (*url.URL, error)

func (*PgAttachmentStore) Retrieve

func (s *PgAttachmentStore) Retrieve(ctx context.Context, storageKey string) (io.ReadCloser, error)

Retrieve fetches attachment data. Numeric storage keys are Java/Go LargeObjects stored via lo_put; UUID keys fall back to the legacy attachment_file_chunks table written by older Go code.

func (*PgAttachmentStore) Store

func (s *PgAttachmentStore) Store(ctx context.Context, data io.Reader, maxSize int64, contentType string) (*registryattach.FileStoreResult, error)

Store buffers the upload to a temp file then writes it to a PostgreSQL LargeObject, matching Java's DatabaseFileStore behaviour. Returns the numeric OID as the storage key.

Jump to

Keyboard shortcuts

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