mongodb

package
v2.25.2 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2026 License: Apache-2.0 Imports: 12 Imported by: 1 module, 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

This section is empty.

Functions

This section is empty.

Types

type DBSub

type DBSub struct {
	ID             string `bson:"_id"`
	URL            string
	CorrelationID  string // uuid
	Type           store.Type
	Accept         []string
	EventTypes     events.EventTypes
	DeviceID       string `bson:"deviceid"`
	Href           string `bson:"href"`
	SequenceNumber uint64 `bson:"sequencenumber"`
	SigningSecret  string
	Initialized    bool `bson:"initialized"`
	AccessToken    string
}

type Store

type Store struct {
	*pkgMongo.Store
}

func NewStore

func NewStore(ctx context.Context, cfg pkgMongo.Config, tls *tls.Config, tracerProvider trace.TracerProvider) (*Store, error)

func (*Store) IncrementSubscriptionSequenceNumber

func (s *Store) IncrementSubscriptionSequenceNumber(ctx context.Context, subscriptionID string) (uint64, error)

func (*Store) LoadSubscriptions

func (s *Store) LoadSubscriptions(ctx context.Context, query store.SubscriptionQuery, h store.SubscriptionHandler) error

func (*Store) PopSubscription

func (s *Store) PopSubscription(ctx context.Context, subscriptionID string) (sub store.Subscription, err error)

func (*Store) SaveSubscription

func (s *Store) SaveSubscription(ctx context.Context, sub store.Subscription) error

func (*Store) SetInitialized

func (s *Store) SetInitialized(ctx context.Context, subscriptionID string) error

Jump to

Keyboard shortcuts

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