mongostore

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2026 License: Apache-2.0 Imports: 14 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ForceImport = 0

ForceImport is a no-op variable that can be referenced to ensure this package's init() runs.

Functions

This section is empty.

Types

type MongoAttachmentStore

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

func (*MongoAttachmentStore) Delete

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

func (*MongoAttachmentStore) GetSignedURL

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

func (*MongoAttachmentStore) Retrieve

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

Retrieve fetches attachment data. ObjectId hex keys (no dashes) are GridFS (Java/Go primary storage); UUID keys with dashes fall back to the legacy attachment_file_chunks collection.

func (*MongoAttachmentStore) Store

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

Store uploads data to GridFS, matching Java's DatabaseFileStore behaviour. Returns the ObjectId hex string as the storage key.

Jump to

Keyboard shortcuts

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