scraper

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2025 License: AGPL-3.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMock

func NewMock() *mockReader

Types

type Config

type Config struct {
	Past     time.Duration
	Interval time.Duration
	Name     string
	Labels   model.Labels
	RSS      *ScrapeSourceRSS
}

func (*Config) Validate

func (c *Config) Validate() error

type Dependencies

type Dependencies struct {
	FeedStorage feed.Storage
	KVStorage   kv.Storage
}

type Factory

--- Factory code block ---

func NewFactory

func NewFactory(mockOn ...component.MockOption) Factory

type ScrapeSourceRSS

type ScrapeSourceRSS struct {
	URL             string
	RSSHubEndpoint  string
	RSSHubRoutePath string
}

--- Interface code block ---

func (*ScrapeSourceRSS) Validate

func (c *ScrapeSourceRSS) Validate() error

type Scraper

type Scraper interface {
	component.Component
	Config() *Config
}

--- Interface code block ---

Jump to

Keyboard shortcuts

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