Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HTTP ¶
type HTTP struct { //URL to poll for new binaries URL string Interval time.Duration CheckHeaders []string // contains filtered or unexported fields }
HTTPFetcher uses HEAD requests to poll the status of a given file. If it detects this file has been updated, it will fetch and return its io.Reader stream.
type Interface ¶
type Interface interface { //Init should perform validation on fields. For //example, ensure the appropriate URLs or keys //are defined or ensure there is connectivity //to the appropriate web service. Init() error //Fetch should check if there is an updated //binary to fetch, and then stream it back the //form of an io.Reader. If io.Reader is nil, //then it is assumed there are no updates. Fetch //will be run repeatly and forever. It is up the //implementation to throttle the fetch frequency. Fetch() (io.Reader, error) }
type S3 ¶
type S3 struct { Access string Secret string Region string Bucket string Key string //interal state Interval time.Duration // contains filtered or unexported fields }
S3 uses authenticated HEAD requests to poll the status of a given object. If it detects this file has been updated, it will perform an object GET and return its io.Reader stream.
Click to show internal directories.
Click to hide internal directories.