Documentation
¶
Index ¶
- type ServerOperation
- type ServerOperationImpl
- func (h *ServerOperationImpl) AuthorizationMiddleware(fn http.HandlerFunc) http.HandlerFunc
- func (h *ServerOperationImpl) BearerProcessorMiddleware(fn http.HandlerFunc) http.HandlerFunc
- func (h *ServerOperationImpl) ChainMiddleware(fn http.HandlerFunc) http.HandlerFunc
- func (c *ServerOperationImpl) HandleRequests(w http.ResponseWriter, r *http.Request)
- func (h *ServerOperationImpl) IPAddressMiddleware(fn http.HandlerFunc) http.HandlerFunc
- func (h *ServerOperationImpl) ProtectedURLsMiddleware(fn http.HandlerFunc) http.HandlerFunc
- func (h *ServerOperationImpl) URLProcessorMiddleware(fn http.HandlerFunc) http.HandlerFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ServerOperation ¶
type ServerOperation struct {
// contains filtered or unexported fields
}
func New ¶
func New(storageAddr string, hmacSecret string, sessionUuid string) (*ServerOperation, error)
func (*ServerOperation) RunMainRuntimeLoop ¶
func (s *ServerOperation) RunMainRuntimeLoop()
Function will consume the main runtime loop and run the business logic of the application.
func (*ServerOperation) StopMainRuntimeLoop ¶
func (s *ServerOperation) StopMainRuntimeLoop()
Function will tell the application to stop the main runtime loop when the process has been finished.
type ServerOperationImpl ¶
type ServerOperationImpl struct {
// contains filtered or unexported fields
}
func (*ServerOperationImpl) AuthorizationMiddleware ¶
func (h *ServerOperationImpl) AuthorizationMiddleware(fn http.HandlerFunc) http.HandlerFunc
func (*ServerOperationImpl) BearerProcessorMiddleware ¶
func (h *ServerOperationImpl) BearerProcessorMiddleware(fn http.HandlerFunc) http.HandlerFunc
func (*ServerOperationImpl) ChainMiddleware ¶
func (h *ServerOperationImpl) ChainMiddleware(fn http.HandlerFunc) http.HandlerFunc
func (*ServerOperationImpl) HandleRequests ¶
func (c *ServerOperationImpl) HandleRequests(w http.ResponseWriter, r *http.Request)
func (*ServerOperationImpl) IPAddressMiddleware ¶
func (h *ServerOperationImpl) IPAddressMiddleware(fn http.HandlerFunc) http.HandlerFunc
func (*ServerOperationImpl) ProtectedURLsMiddleware ¶
func (h *ServerOperationImpl) ProtectedURLsMiddleware(fn http.HandlerFunc) http.HandlerFunc
The purpose of this middleware is to return a `401 unauthorized` error if the user is not authorized and visiting a protected URL.
func (*ServerOperationImpl) URLProcessorMiddleware ¶
func (h *ServerOperationImpl) URLProcessorMiddleware(fn http.HandlerFunc) http.HandlerFunc
Middleware will split the full URL path into slash-sperated parts and save to the context to flow downstream in the app for this particular request.
Click to show internal directories.
Click to hide internal directories.