2020-12-23 13:27:17 +05:00
|
|
|
package models
|
|
|
|
|
|
|
|
// RequestInfo is a parsed request information to throw into application's handler.
|
|
|
|
type RequestInfo struct {
|
2020-12-23 20:55:50 +05:00
|
|
|
// Application is a name of application. We should ask it's handler for metrics.
|
2020-12-23 13:27:17 +05:00
|
|
|
Application string
|
2020-12-23 20:55:50 +05:00
|
|
|
// Metric is a metric name with parameters (e.g. requests{path='/',code=200} will
|
|
|
|
// be "requests/path:\//code:200").
|
|
|
|
Metric string
|
|
|
|
// Request type is a type of request. Currently known: "apps_list", "info", and "metrics".
|
|
|
|
// All other request types will produce HTTP 400 error.
|
2020-12-23 13:27:17 +05:00
|
|
|
RequestType string
|
2020-12-23 20:55:50 +05:00
|
|
|
// APIVersion is a version of API requested.
|
|
|
|
APIVersion int
|
2020-12-23 13:27:17 +05:00
|
|
|
}
|