firestore

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BackupProcessor

type BackupProcessor interface {
	Backup() error
	Restore() error
}

func NewBackupProcessor

func NewBackupProcessor(firestoreReader FirestoreInterface, storage output.DatabaseBackupStorage) BackupProcessor

type FirestoreDocument

type FirestoreDocument struct {
	Path string
	Id   string
	Data map[string]interface{}
}

type FirestoreInterface

type FirestoreInterface interface {
	io.Closer
	Process(documentsChan chan *FirestoreDocument) error
	Insert(document []*FirestoreDocument) error
}

type FirestoreReaderBuilder

type FirestoreReaderBuilder interface {
	//WithCollections collections to be extracted default: all
	WithCollections([]string) FirestoreReaderBuilder
	WithStartingTime(time time.Time) FirestoreReaderBuilder
	WithEndingTime(time time.Time) FirestoreReaderBuilder
	WithTimeField(string) FirestoreReaderBuilder
	// WithDatabaseName (default)
	WithDatabaseName(string) FirestoreReaderBuilder
	Build() (FirestoreInterface, error)
}

func NewFirestoreReaderBuilder

func NewFirestoreReaderBuilder(client *firestore.Client) FirestoreReaderBuilder

type MarshallingError

type MarshallingError struct {
	Message string
}

func (MarshallingError) Error

func (s MarshallingError) Error() string

type ServerError

type ServerError struct {
	Message string
}

func (ServerError) Error

func (s ServerError) Error() string

Jump to

Keyboard shortcuts

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