コード例 #1
0
ファイル: model.go プロジェクト: badoo/thunder
func setInitJobsTs(tx *db.LazyTrx, className string, locations []string) (err error) {
	if len(locations) == 0 {
		return
	}

	_, err = tx.Exec(
		QUERY_SET_INIT_JOBS_TS,
		"class_name", className,
		"locations", db.INStr(locations))
	return
}
コード例 #2
0
ファイル: model.go プロジェクト: badoo/thunder
func setJobsGeneratedTs(tx *db.LazyTrx, className string, locations []string) (err error) {
	if len(locations) == 0 {
		return
	}

	_, err = tx.Exec(
		QUERY_SET_JOBS_GENERATED_TS,
		"class_name", className,
		"locations", db.INStr(locations))
	return
}
コード例 #3
0
ファイル: model.go プロジェクト: badoo/thunder
func clearJobsResultsForLocations(tx *db.LazyTrx, className string, locations []string) (err error) {
	if len(locations) == 0 {
		return
	}

	_, err = tx.Exec(
		QUERY_CLEAR_JOB_RESULTS_FOR_LOCATIONS,
		"class_name", className,
		"locations", db.INStr(locations))
	return
}