Documentation
¶
Index ¶
- func AppInfo(app string, version string) func(http.Handler) http.Handler
- func Logger(ipFn func(ip string) string, flags ...LoggerFlag) func(http.Handler) http.Handler
- func Ping(next http.Handler) http.Handler
- func Recoverer(next http.Handler) http.Handler
- type JSON
- type LoggerFlag
- type Migrator
- type Rest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type LoggerFlag ¶
type LoggerFlag int
LoggerFlag type
const ( LogAll LoggerFlag = iota LogUser LogBody LogNone )
logger flags enum
type Migrator ¶
type Migrator struct {
Version string
Cache cache.LoadingCache
NativeImporter migrator.Importer
DisqusImporter migrator.Importer
NativeExported migrator.Exporter
SecretKey string
// contains filtered or unexported fields
}
Migrator rest runs on unexposed port and available for local requests only
type Rest ¶
type Rest struct {
Version string
DataService *service.DataStore
Authenticator auth.Authenticator
Exporter migrator.Exporter
Cache cache.LoadingCache
AvatarProxy *proxy.Avatar
ImageProxy *proxy.Image
WebRoot string
RemarkURL string
ReadOnlyAge int
ScoreThresholds struct {
Low int
Critical int
}
// contains filtered or unexported fields
}
Rest is a rest access server
Click to show internal directories.
Click to hide internal directories.