Documentation ¶
Index ¶
- Variables
- func GetData(w http.ResponseWriter, req *http.Request)
- func GetDataIndex(w http.ResponseWriter, req *http.Request)
- func GetDataName(w http.ResponseWriter, req *http.Request)
- func GetIndex(w http.ResponseWriter, req *http.Request)
- func NewRouter() *mux.Router
- func Root(w http.ResponseWriter, req *http.Request)
- func Tracer(method, url, body string)
- type Route
- type RoutesV1
Constants ¶
This section is empty.
Variables ¶
View Source
var Elastic *elastic.Client
Functions ¶
func GetData ¶
func GetData(w http.ResponseWriter, req *http.Request)
GetData gets V1 data Return entry curl -XGET 'http://HOST:PORT/v1/data/NAME, equivalent to curl -XGET 'http://HOST:PORT/v1/data?name=NAME'
curl -XGET 'http://HOST:PORT/v1/data/NAME,
func GetDataIndex ¶
func GetDataIndex(w http.ResponseWriter, req *http.Request)
GetDataIndex lists all data and or queries them Return all entries curl -XGET 'http://HOST:PORT/v1/data
Can search for specific fields curl -XGET 'http://HOST:PORT/v1/data?key=val&key2=val2'
func GetDataName ¶
func GetDataName(w http.ResponseWriter, req *http.Request)
GetDataName gets V1 data curl -XGET 'http://HOST:PORT/v1/data/NAME, equivalent to curl -XGET 'http://HOST:PORT/v1/data?name=NAME'
Types ¶
Click to show internal directories.
Click to hide internal directories.