Documentation
¶
Index ¶
- Variables
- func BatchInsertItems(repo Repository) func(ctx context.Context, i interface{}) (interface{}, error)
- func DispatchChecksumFetch() func(context.Context, interface{}) (interface{}, error)
- func FetchFiles(k *koanf.Koanf, dataRepo Repository) (map[string]string, error)
- func NotNilFilter() func(i interface{}) bool
- func ParseDumpModel(ctx context.Context) func(item rxgo.Item) rxgo.Observable
- func PopulateFromUri() func(ctx context.Context, i interface{}) (interface{}, error)
- func SetChecksumValues(m map[time.Time]map[string]string) func(ctx context.Context, i interface{}) (interface{}, error)
- func UpdateData(ctx context.Context, repo Repository) (int, error)
- func ValidUriFilter() func(i interface{}) bool
- type Data
- type Repository
Constants ¶
This section is empty.
Variables ¶
View Source
var DiscogsS3BaseUrl = "https://discogs-data-dumps.s3-us-west-2.amazonaws.com/"
Functions ¶
func BatchInsertItems ¶
func BatchInsertItems(repo Repository) func(ctx context.Context, i interface{}) (interface{}, error)
func DispatchChecksumFetch ¶
func FetchFiles ¶
func NotNilFilter ¶
func NotNilFilter() func(i interface{}) bool
func ParseDumpModel ¶
func PopulateFromUri ¶
func SetChecksumValues ¶
func UpdateData ¶
func UpdateData(ctx context.Context, repo Repository) (int, error)
func ValidUriFilter ¶
func ValidUriFilter() func(i interface{}) bool
ValidUriFilter filter items by validating URI, judged by date, types and uri pattern.
Types ¶
type Data ¶
type Repository ¶
type Repository interface { BatchInsert([]*Data) (int, error) FindByYearMonthType(year, month, typ string) (*Data, error) }
func NewDataRepository ¶
func NewDataRepository(db *gorm.DB) Repository
Click to show internal directories.
Click to hide internal directories.