Documentation ¶
Index ¶
Constants ¶
View Source
const ( ColID = "Id" ColNextExecutionTime = "NextExecutionTime" ColLastExecutedAt = "LastExecutedAt" ColDeletedAt = "DeletedAt" ColCreatedAt = "CreatedAt" ColCircleID = "CircleId" ColName = "Name" ColExecutionInterval = "ExecutionInterval" ColIsLocked = "IsLocked" )
View Source
const ( TableJobs = "Jobs" TableExecutedJobs = "ExecutedJobs" TableCircles = "Circles" TableCircleData = "CircleData" )
Variables ¶
View Source
var InitialJobs = []Job{ { ID: "1", Name: "Circle_Single", ExecutionInterval: Period{ Count: 1, Timeunit: Hour, }.ToString(), NextExecutionTime: time.Now().Add(time.Hour), CreatedAt: spanner.CommitTimestamp, }, }
Functions ¶
This section is empty.
Types ¶
type CircleCountData ¶
func (CircleCountData) FromProto ¶
func (c CircleCountData) FromProto(in *analyticsV1.GetCircleCountDataResponse_CircleCountDataHolder) CircleCountData
type CircleCountDataList ¶
type CircleCountDataList []CircleCountData
func (CircleCountDataList) ToCircleCountDataProto ¶
func (c CircleCountDataList) ToCircleCountDataProto() []*analyticsV1.GetCircleCountDataResponse_CircleCountDataHolder
type CircleData ¶
type CircleData struct { ID string `spanner:"Id"` CircleID string `spanner:"CircleId"` MembersCount int64 `spanner:"MembersCount"` ViewsCount int64 `spanner:"ViewsCount"` PostsCount int64 `spanner:"PostsCount"` CreatedAt time.Time `spanner:"CreatedAt"` }
func (CircleData) ToProto ¶
func (c CircleData) ToProto() *analyticsV1.CircleData
type CircleDataSlice ¶
type CircleDataSlice []CircleData
func (CircleDataSlice) ToProto ¶
func (cds CircleDataSlice) ToProto() []*analyticsV1.CircleData
type CountDataArray ¶
type CountDataArray []CountData
func (CountDataArray) SortByTimeAscending ¶
func (c CountDataArray) SortByTimeAscending()
func (CountDataArray) ToCountDataHolderPB ¶
func (c CountDataArray) ToCountDataHolderPB() []*analyticsV1.CountDataHolder
type ExecutedJob ¶
type Job ¶
type Job struct { ID string `spanner:"Id"` Name string `spanner:"Name"` ExecutionInterval string `spanner:"ExecutionInterval"` LastExecutedAt spanner.NullTime `spanner:"LastExecutedAt"` NextExecutionTime time.Time `spanner:"NextExecutionTime"` IsLocked bool `spanner:"IsLocked"` CreatedAt time.Time `spanner:"CreatedAt"` }
func (Job) GetColumNames ¶
type Period ¶
func PeriodFromProto ¶
func PeriodFromProto(p analyticsV1.Period) (*Period, error)
func PeriodFromString ¶
func (Period) GetTimeFromForQuerying ¶
func (Period) ToDuration ¶
Click to show internal directories.
Click to hide internal directories.