isync

package
v0.0.0-...-5eee607 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2023 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Sync

type Sync struct {
	ConnSpec  pg.ConnSpec
	DB        pg.DB
	CacheDir  string
	Loader    *loader.Loader
	Servers   sources.Servers
	Schema    *db.CrawlSchema
	CrawlData data.Crawl
	Fetcher   *logfetch.Fetcher
	// contains filtered or unexported fields
}

Sync is the master isync state object, keeping track of the logs to sync, the database and the log fetcher.

func New

func New(c pg.ConnSpec, cachedir string) (*Sync, error)

New creates a new sync object given a database connection spec and a cache directory to save logs.

func (*Sync) Run

func (l *Sync) Run() error

Run monitors stdin for commands.

func (*Sync) Shutdown

func (l *Sync) Shutdown()

Shutdown stops the isync process, gracefully quitting all tasks.

Jump to

Keyboard shortcuts

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