Documentation ¶
Overview ¶
Returns global and policy-level statistics about actions taken by snapshot lifecycle management.
Index ¶
- Variables
- type GetStats
- func (r GetStats) Do(ctx context.Context) (*Response, error)
- func (r *GetStats) Header(key, value string) *GetStats
- func (r *GetStats) HttpRequest(ctx context.Context) (*http.Request, error)
- func (r GetStats) IsSuccess(ctx context.Context) (bool, error)
- func (r GetStats) Perform(ctx context.Context) (*http.Response, error)
- type NewGetStats
- type Response
Constants ¶
This section is empty.
Variables ¶
var ErrBuildPath = errors.New("cannot build path, check for missing path parameters")
ErrBuildPath is returned in case of missing parameters within the build of the request.
Functions ¶
This section is empty.
Types ¶
type GetStats ¶
type GetStats struct {
// contains filtered or unexported fields
}
func New ¶
func New(tp elastictransport.Interface) *GetStats
Returns global and policy-level statistics about actions taken by snapshot lifecycle management.
https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-get-stats.html
func (GetStats) Do ¶
Do runs the request through the transport, handle the response and returns a getstats.Response
func (*GetStats) HttpRequest ¶
HttpRequest returns the http.Request object built from the given parameters.
type NewGetStats ¶
type NewGetStats func() *GetStats
NewGetStats type alias for index.
func NewGetStatsFunc ¶
func NewGetStatsFunc(tp elastictransport.Interface) NewGetStats
NewGetStatsFunc returns a new instance of GetStats with the provided transport. Used in the index of the library this allows to retrieve every apis in once place.
type Response ¶ added in v8.7.0
type Response struct { PolicyStats []string `json:"policy_stats"` RetentionDeletionTime types.Duration `json:"retention_deletion_time"` RetentionDeletionTimeMillis int64 `json:"retention_deletion_time_millis"` RetentionFailed int64 `json:"retention_failed"` RetentionRuns int64 `json:"retention_runs"` RetentionTimedOut int64 `json:"retention_timed_out"` TotalSnapshotDeletionFailures int64 `json:"total_snapshot_deletion_failures"` TotalSnapshotsDeleted int64 `json:"total_snapshots_deleted"` TotalSnapshotsFailed int64 `json:"total_snapshots_failed"` TotalSnapshotsTaken int64 `json:"total_snapshots_taken"` }