Documentation ¶
Index ¶
- func CleanupDOmain(domain string) string
- func Reduce(metrics []string) func(*Stats, map[string]any)
- func StatToValue(metric string) func(s *Stats) float64
- type And
- type DB
- func (db *DB) APIKeys() (ls []*v1.APIKey, err error)
- func (db *DB) Badger() *badger.DB
- func (db *DB) Close() error
- func (db *DB) CreateAPIKey(name string, key string) error
- func (db *DB) CreateSite(domain string, public bool) (err error)
- func (db *DB) DeleteAPIKey(name string) error
- func (db *DB) DeleteDomain(domain string) (err error)
- func (db *DB) DeleteSharedLink(site *v1.Site, slug string) error
- func (db *DB) Domains(f func(*v1.Site))
- func (db *DB) EditSharedLink(site *v1.Site, slug, name string) error
- func (db *DB) FindOrCreateCreateSharedLink(domain string, name, password string) (share *v1.Share)
- func (db *DB) Save(u *v1.Site) error
- func (db *DB) SeenFirstStats(domain string) (ok bool)
- func (db *DB) SetupDomains(domains []string)
- func (db *DB) Site(domain string) (u *v1.Site)
- func (db *DB) Start(ctx context.Context)
- func (db *DB) Update(f func(tx *Tx) error) error
- func (db *DB) ValidAPIKkey(key string) bool
- func (db *DB) ValidateSiteDomain(domain string) (good, bad string)
- func (db *DB) View(f func(tx *Tx) error) error
- type Filter
- type Match
- type Reject
- type Result
- type Stats
- type Store
- func (o *Store) Breakdown(domain string, params *query.Query, metrics []string, field v1.Field) (*Result, error)
- func (o *Store) BreakdownCity(domain string, params *query.Query, metrics []string) (*Result, error)
- func (o *Store) BreakdownExitPages(domain string, params *query.Query) (*Result, error)
- func (o *Store) BreakdownVisitorsWithPercentage(domain string, params *query.Query, field v1.Field) (*Result, error)
- func (o *Store) CurrentVisitors(domain string) (visitors uint64, err error)
- func (s *Store) Delete(_ context.Context, key string) error
- func (s *Store) Get(_ context.Context, key string) ([]byte, error)
- func (s *Store) Put(_ context.Context, key string, data []byte) error
- func (o *Store) Stats(domain string, start, end time.Time, interval query.Interval, ...) (*Stats, error)
- func (o *Store) Timeseries(domain string, params *query.Query, metrics []string) (map[string]*Stats, error)
- func (o *Store) Visitors(domain string) (visitors uint64, err error)
- func (o *Store) Web() (secret *age.X25519Identity, err error)
- type Tx
- func (tx *Tx) Bitmap(shard, view uint64, field v1.Field, f func(bs *roaring.BSI)) error
- func (tx *Tx) Close()
- func (tx *Tx) Count(shard, view uint64, field v1.Field, match *roaring.Bitmap) (count uint64, err error)
- func (tx *Tx) Find(field v1.Field, id uint64) (o string)
- func (tx *Tx) ID(field v1.Field, value []byte) (id uint64, ok bool)
- func (tx *Tx) Iter() *badger.Iterator
- func (tx *Tx) RecordID() uint64
- func (tx *Tx) Release()
- func (tx *Tx) Search(field v1.Field, prefix []byte, f func([]byte, uint64))
- func (tx *Tx) Select(domain string, start, end time.Time, intrerval query.Interval, ...) error
- func (tx *Tx) Sum(shard, view uint64, field v1.Field, match *roaring.Bitmap) (sum int64, err error)
- func (tx *Tx) Translate(field v1.Field, value []byte) (id uint64)
- func (tx *Tx) Transpose(shard, view uint64, field v1.Field, match *roaring.Bitmap) (result *roaring.Bitmap, err error)
- func (tx *Tx) TransposeSet(shard, view uint64, field v1.Field, match *roaring.Bitmap) (result map[int64][]uint64, err error)
- func (tx *Tx) Unique(shard, view uint64, field v1.Field, match *roaring.Bitmap) (uint64, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanupDOmain ¶
func StatToValue ¶
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
func (*DB) DeleteAPIKey ¶ added in v1.1.0
func (*DB) DeleteDomain ¶
func (*DB) FindOrCreateCreateSharedLink ¶
func (*DB) SeenFirstStats ¶
func (*DB) SetupDomains ¶ added in v1.3.0
func (*DB) ValidAPIKkey ¶ added in v1.1.0
func (*DB) ValidateSiteDomain ¶
type Stats ¶
type Stats struct { Visitors, Visits, PageViews, ViewsPerVisits, BounceRate, VisitDuration float64 // contains filtered or unexported fields }
type Store ¶
type Store struct {
*DB
}
func (*Store) BreakdownCity ¶
func (*Store) BreakdownExitPages ¶
func (*Store) BreakdownVisitorsWithPercentage ¶
func (*Store) CurrentVisitors ¶
func (*Store) Timeseries ¶
Click to show internal directories.
Click to hide internal directories.