Documentation
¶
Index ¶
- Constants
- func StartReporters(session *Session)
- type PriorityEntry
- type Reporter
- type RequestQueue
- func (rq *RequestQueue) Delete(url string, data interface{}, priority int, due time.Time)
- func (rq *RequestQueue) Patch(url string, data interface{}, priority int, due time.Time)
- func (rq *RequestQueue) Post(url string, data interface{}, priority int, due time.Time)
- func (rq *RequestQueue) Put(url string, data interface{}, priority int, due time.Time)
- type Session
- func (session *Session) CheckSession(ctx context.Context) bool
- func (session *Session) Delete(url string, rawBody interface{}, timeout time.Duration) ([]byte, int, error)
- func (session *Session) Get(url string, timeout time.Duration) ([]byte, int, error)
- func (session *Session) MultipartRequest(url string, body bytes.Buffer, contentType string, timeout time.Duration) ([]byte, int, error)
- func (session *Session) Patch(url string, rawBody interface{}, timeout time.Duration) ([]byte, int, error)
- func (session *Session) Post(url string, rawBody interface{}, timeout time.Duration) ([]byte, int, error)
- func (session *Session) Put(url string, rawBody interface{}, timeout time.Duration) ([]byte, int, error)
- func (session *Session) Request(method, url string, rawBody interface{}, timeout time.Duration) ([]byte, int, error)
Constants ¶
View Source
const ( RetryLimit = 5 MaxQueueSize = 10 * 60 * 60 // 10 entries/second * 1h )
View Source
const (
MaxRetryTimeout = 3 * 24 * time.Hour
)
Variables ¶
This section is empty.
Functions ¶
func StartReporters ¶
func StartReporters(session *Session)
Types ¶
type PriorityEntry ¶
type PriorityEntry struct {
// contains filtered or unexported fields
}
queue //
type Reporter ¶
type Reporter struct {
// contains filtered or unexported fields
}
reporter //
func NewReporter ¶
type RequestQueue ¶
type RequestQueue struct {
// contains filtered or unexported fields
}
var (
Rqueue *RequestQueue
)
func (*RequestQueue) Delete ¶
func (rq *RequestQueue) Delete(url string, data interface{}, priority int, due time.Time)
func (*RequestQueue) Patch ¶
func (rq *RequestQueue) Patch(url string, data interface{}, priority int, due time.Time)
Click to show internal directories.
Click to hide internal directories.