Documentation ¶
Index ¶
- type DataView
- type DestinationView
- type GlobalActionsView
- type Hoverfly
- type HoverflyDestination
- type HoverflyDestinationHandler
- func (this *HoverflyDestinationHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
- func (this *HoverflyDestinationHandler) Put(w http.ResponseWriter, r *http.Request, next http.HandlerFunc)
- func (this *HoverflyDestinationHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
- type HoverflyHandler
- type HoverflyMiddleware
- type HoverflyMiddlewareHandler
- func (this *HoverflyMiddlewareHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
- func (this *HoverflyMiddlewareHandler) Put(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
- func (this *HoverflyMiddlewareHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
- type HoverflyMode
- type HoverflyModeHandler
- type HoverflySimulation
- type HoverflyUpstreamProxy
- type HoverflyUpstreamProxyHandler
- type HoverflyUsage
- type HoverflyUsageHandler
- type HoverflyVersion
- type HoverflyVersionHandler
- type HoverflyView
- type MetaView
- type MiddlewareView
- type ModeView
- type RequestDetailsView
- func (this RequestDetailsView) GetBody() *string
- func (this RequestDetailsView) GetDestination() *string
- func (this RequestDetailsView) GetHeaders() map[string][]string
- func (this RequestDetailsView) GetMethod() *string
- func (this RequestDetailsView) GetPath() *string
- func (this RequestDetailsView) GetQuery() *string
- func (this RequestDetailsView) GetRequestType() *string
- func (this RequestDetailsView) GetScheme() *string
- type RequestResponsePairView
- type ResponseDetailsView
- type SimulationHandler
- func (this *SimulationHandler) Delete(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
- func (this *SimulationHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
- func (this *SimulationHandler) Put(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
- func (this *SimulationHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
- type SimulationView
- type UpstreamProxyView
- type UsageView
- type VersionView
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataView ¶
type DataView struct { RequestResponsePairs []RequestResponsePairView `json:"pairs"` GlobalActions GlobalActionsView `json:"globalActions"` }
type DestinationView ¶
type DestinationView struct {
Destination string `json:"destination"`
}
type GlobalActionsView ¶
type GlobalActionsView struct {
Delays []v1.ResponseDelayView `json:"delays"`
}
type HoverflyDestination ¶
type HoverflyDestinationHandler ¶
type HoverflyDestinationHandler struct {
Hoverfly HoverflyDestination
}
func (*HoverflyDestinationHandler) Get ¶
func (this *HoverflyDestinationHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*HoverflyDestinationHandler) Put ¶
func (this *HoverflyDestinationHandler) Put(w http.ResponseWriter, r *http.Request, next http.HandlerFunc)
func (*HoverflyDestinationHandler) RegisterRoutes ¶
func (this *HoverflyDestinationHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
type HoverflyHandler ¶
type HoverflyHandler struct {
Hoverfly Hoverfly
}
func (*HoverflyHandler) Get ¶
func (this *HoverflyHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*HoverflyHandler) RegisterRoutes ¶
func (this *HoverflyHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
type HoverflyMiddleware ¶
type HoverflyMiddlewareHandler ¶
type HoverflyMiddlewareHandler struct {
Hoverfly HoverflyMiddleware
}
func (*HoverflyMiddlewareHandler) Get ¶
func (this *HoverflyMiddlewareHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*HoverflyMiddlewareHandler) Put ¶
func (this *HoverflyMiddlewareHandler) Put(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*HoverflyMiddlewareHandler) RegisterRoutes ¶
func (this *HoverflyMiddlewareHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
type HoverflyMode ¶
type HoverflyModeHandler ¶
type HoverflyModeHandler struct {
Hoverfly HoverflyMode
}
func (*HoverflyModeHandler) Get ¶
func (this *HoverflyModeHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*HoverflyModeHandler) Put ¶
func (this *HoverflyModeHandler) Put(w http.ResponseWriter, r *http.Request, next http.HandlerFunc)
func (*HoverflyModeHandler) RegisterRoutes ¶
func (this *HoverflyModeHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
type HoverflySimulation ¶
type HoverflySimulation interface { GetSimulation() (SimulationView, error) PutSimulation(SimulationView) error DeleteSimulation() }
type HoverflyUpstreamProxy ¶ added in v0.10.1
type HoverflyUpstreamProxy interface {
GetUpstreamProxy() string
}
type HoverflyUpstreamProxyHandler ¶ added in v0.10.1
type HoverflyUpstreamProxyHandler struct {
Hoverfly HoverflyUpstreamProxy
}
func (*HoverflyUpstreamProxyHandler) Get ¶ added in v0.10.1
func (this *HoverflyUpstreamProxyHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*HoverflyUpstreamProxyHandler) RegisterRoutes ¶ added in v0.10.1
func (this *HoverflyUpstreamProxyHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
type HoverflyUsage ¶
type HoverflyUsageHandler ¶
type HoverflyUsageHandler struct {
Hoverfly HoverflyUsage
}
func (*HoverflyUsageHandler) Get ¶
func (this *HoverflyUsageHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*HoverflyUsageHandler) RegisterRoutes ¶
func (this *HoverflyUsageHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
type HoverflyVersion ¶ added in v0.10.1
type HoverflyVersion interface {
GetVersion() string
}
type HoverflyVersionHandler ¶ added in v0.10.1
type HoverflyVersionHandler struct {
Hoverfly HoverflyVersion
}
func (*HoverflyVersionHandler) Get ¶ added in v0.10.1
func (this *HoverflyVersionHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*HoverflyVersionHandler) RegisterRoutes ¶ added in v0.10.1
func (this *HoverflyVersionHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
type HoverflyView ¶
type HoverflyView struct { DestinationView MiddlewareView `json:"middleware"` ModeView UsageView VersionView UpstreamProxyView }
type MiddlewareView ¶
type RequestDetailsView ¶
type RequestDetailsView struct { RequestType *string `json:"requestType"` Path *string `json:"path"` Method *string `json:"method"` Destination *string `json:"destination"` Scheme *string `json:"scheme"` Query *string `json:"query"` Body *string `json:"body"` Headers map[string][]string `json:"headers"` }
RequestDetailsView is used when marshalling and unmarshalling RequestDetails
func (RequestDetailsView) GetBody ¶
func (this RequestDetailsView) GetBody() *string
Gets Body - required for interfaces.Request
func (RequestDetailsView) GetDestination ¶
func (this RequestDetailsView) GetDestination() *string
Gets Destination - required for interfaces.Request
func (RequestDetailsView) GetHeaders ¶
func (this RequestDetailsView) GetHeaders() map[string][]string
Gets Headers - required for interfaces.Request
func (RequestDetailsView) GetMethod ¶
func (this RequestDetailsView) GetMethod() *string
Gets Method - required for interfaces.Request
func (RequestDetailsView) GetPath ¶
func (this RequestDetailsView) GetPath() *string
Gets Path - required for interfaces.Request
func (RequestDetailsView) GetQuery ¶
func (this RequestDetailsView) GetQuery() *string
Gets Query - required for interfaces.Request
func (RequestDetailsView) GetRequestType ¶
func (this RequestDetailsView) GetRequestType() *string
Gets RequestType - required for interfaces.Request
func (RequestDetailsView) GetScheme ¶
func (this RequestDetailsView) GetScheme() *string
Gets Scheme - required for interfaces.Request
type RequestResponsePairView ¶
type RequestResponsePairView struct { Response ResponseDetailsView `json:"response"` Request RequestDetailsView `json:"request"` }
func (RequestResponsePairView) GetRequest ¶
func (this RequestResponsePairView) GetRequest() interfaces.Request
Gets Request - required for interfaces.RequestResponsePairView
func (RequestResponsePairView) GetResponse ¶
func (this RequestResponsePairView) GetResponse() interfaces.Response
Gets Response - required for interfaces.RequestResponsePairView
type ResponseDetailsView ¶
type ResponseDetailsView struct { Status int `json:"status"` Body string `json:"body"` EncodedBody bool `json:"encodedBody"` Headers map[string][]string `json:"headers"` }
ResponseDetailsView is used when marshalling and unmarshalling requests. This struct's Body may be Base64 encoded based on the EncodedBody field.
func (ResponseDetailsView) GetBody ¶
func (this ResponseDetailsView) GetBody() string
Gets Body - required for interfaces.Response
func (ResponseDetailsView) GetEncodedBody ¶
func (this ResponseDetailsView) GetEncodedBody() bool
Gets EncodedBody - required for interfaces.Response
func (ResponseDetailsView) GetHeaders ¶
func (this ResponseDetailsView) GetHeaders() map[string][]string
Gets Headers - required for interfaces.Response
func (ResponseDetailsView) GetStatus ¶
func (this ResponseDetailsView) GetStatus() int
Gets Status - required for interfaces.Response
type SimulationHandler ¶
type SimulationHandler struct {
Hoverfly HoverflySimulation
}
func (*SimulationHandler) Delete ¶
func (this *SimulationHandler) Delete(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*SimulationHandler) Get ¶
func (this *SimulationHandler) Get(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*SimulationHandler) Put ¶
func (this *SimulationHandler) Put(w http.ResponseWriter, req *http.Request, next http.HandlerFunc)
func (*SimulationHandler) RegisterRoutes ¶
func (this *SimulationHandler) RegisterRoutes(mux *bone.Mux, am *handlers.AuthHandler)
type SimulationView ¶
func (SimulationView) GetValidationSchema ¶ added in v0.9.2
func (this SimulationView) GetValidationSchema() valid.Validator
type UpstreamProxyView ¶ added in v0.10.1
type UpstreamProxyView struct {
UpstreamProxy string `json:"upstream-proxy"`
}
type VersionView ¶ added in v0.10.1
type VersionView struct {
Version string `json:"version"`
}