analytics

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2023 License: MPL-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DailyEventCount         string = "Daily Event Count"
	DailyOrganisationCount  string = "Daily Organization Count"
	DailyProjectCount       string = "Daily Project Count"
	DailyActiveProjectCount string = "Daily Active Project Count"
	DailyUserCount          string = "Daily User Count"
	MixPanelDevToken        string = "YTAwYWI1ZWE3OTE2MzQwOWEwMjk4ZTA1NTNkNDQ0M2M="
	MixPanelProdToken       string = "YWViNzUwYWRmYjM0YTZmZjJkMzg2YTYyYWVhY2M2NWI="
	PerPage                 int    = 50
	Page                    int    = 1
)

Variables

View Source
var DefaultCursor = fmt.Sprintf("%d", math.MaxInt)

Functions

func TrackDailyAnalytics

func TrackDailyAnalytics(db database.Database, cfg config.Configuration, rd *rdb.Redis) func(context.Context, *asynq.Task) error

Types

type ActiveProjectAnalytics added in v0.8.0

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

func (*ActiveProjectAnalytics) Name added in v0.8.0

func (a *ActiveProjectAnalytics) Name() string

func (*ActiveProjectAnalytics) Track added in v0.8.0

func (a *ActiveProjectAnalytics) Track() error

type Analytics

type Analytics struct {
	Repo *Repo
	// contains filtered or unexported fields
}

func (*Analytics) RegisterTrackers

func (a *Analytics) RegisterTrackers()

type AnalyticsClient

type AnalyticsClient interface {
	Export(eventName string, e Event) error
}

type Event

type Event map[string]interface{}

type EventAnalytics

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

func (*EventAnalytics) Name

func (ea *EventAnalytics) Name() string

func (*EventAnalytics) Track

func (ea *EventAnalytics) Track() error

type MixPanelClient

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

func NewMixPanelClient

func NewMixPanelClient(cfg config.Configuration) (*MixPanelClient, error)

func (*MixPanelClient) Export

func (m *MixPanelClient) Export(eventName string, e Event) error

type NoopAnalyticsClient

type NoopAnalyticsClient struct{}

func NewNoopAnalyticsClient

func NewNoopAnalyticsClient() *NoopAnalyticsClient

func (*NoopAnalyticsClient) Export

func (n *NoopAnalyticsClient) Export(eventName string, e Event) error

type OrganisationAnalytics

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

func (*OrganisationAnalytics) Name

func (o *OrganisationAnalytics) Name() string

func (*OrganisationAnalytics) Track

func (o *OrganisationAnalytics) Track() error

type ProjectAnalytics added in v0.8.0

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

func (*ProjectAnalytics) Name added in v0.8.0

func (g *ProjectAnalytics) Name() string

func (*ProjectAnalytics) Track added in v0.8.0

func (g *ProjectAnalytics) Track() error

type Repo

type Repo struct {
	ConfigRepo datastore.ConfigurationRepository
	EventRepo  datastore.EventRepository

	OrgRepo  datastore.OrganisationRepository
	UserRepo datastore.UserRepository
	// contains filtered or unexported fields
}

type Tracker

type Tracker interface {
	Track() error
	Name() string
}

type UserAnalytics

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

func (*UserAnalytics) Name

func (u *UserAnalytics) Name() string

func (*UserAnalytics) Track

func (u *UserAnalytics) Track() error

Jump to

Keyboard shortcuts

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