Documentation ¶
Index ¶
- func DefaultMiddleware() []func(http.Handler) http.Handler
- type BuildVersionInfo
- type Option
- func RegisterOtoServer(otoServer *otohttp.Server) Option
- func RegisterService(svc domain.Service) Option
- func SetBuildVersionInfo(info *BuildVersionInfo) Option
- func SetDisableRequestLogger() Option
- func SetEnableIntrospect(enabled bool) Option
- func SetEnableLegacyConfig(cfgFile string) Option
- func SetEnableSentry(dsn string) Option
- func SetIgnore404Paths(paths []string) Option
- func SetLegacyRouters(routers ...RouterFunc) Option
- func SetLogger(l *logger.CustomLogger) Option
- func SetMetricsPort(port int) Option
- func SetMiddleware(middleware ...func(next http.Handler) http.Handler) Option
- func SetOrganisationService(svc *organization.Service) Option
- func SetPort(port int) Option
- func SetRouters(rb ...RouterFunc) Option
- func SetShutdownHook(name string, hook Shutdown) Option
- func SetStaticFS(static fs.FS) Option
- func SetTLS(cert, key string) Option
- type RouterFunc
- type Server
- type Service
- type Shutdown
- type WorkerService
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BuildVersionInfo ¶ added in v0.1.8
type BuildVersionInfo struct { Version string `json:"number"` Commit string `json:"commit"` BuildAgent string `json:"buildAgent"` BuildDate string `json:"buildDate"` BuildID string `json:"buildID"` }
BuildVersionInfo holds all the version information
func NewBuildVersionInfo ¶ added in v0.1.8
func NewBuildVersionInfo(version, commit, buildagent, builddate string) *BuildVersionInfo
NewBuildVersionInfo creates a BuildVersionInfo struct
func (*BuildVersionInfo) String ¶ added in v0.1.8
func (info *BuildVersionInfo) String() string
type Option ¶
type Option func(*server) error
Option is a closure to configure the Server. It is used in NewServer.
func RegisterOtoServer ¶ added in v0.2.1
RegisterOtoServer registers an otohttp.Server.
This enables the server to expose RPC on the '/oto/' endpoint
func RegisterService ¶ added in v0.3.0
RegisterService registers a Service with the ikuzo server
func SetBuildVersionInfo ¶ added in v0.1.8
func SetBuildVersionInfo(info *BuildVersionInfo) Option
func SetDisableRequestLogger ¶
func SetDisableRequestLogger() Option
SetDisableRequestLogger disables logging of HTTP request
func SetEnableIntrospect ¶ added in v0.3.0
func SetEnableLegacyConfig ¶ added in v0.1.8
func SetEnableSentry ¶ added in v0.3.0
func SetIgnore404Paths ¶ added in v0.3.0
func SetLegacyRouters ¶ added in v0.1.8
func SetLegacyRouters(routers ...RouterFunc) Option
func SetLogger ¶ added in v0.1.8
func SetLogger(l *logger.CustomLogger) Option
SetLogger configures the global logger for the server.
func SetMetricsPort ¶ added in v0.1.8
SetMetricsPort sets the TCP port for the metrics server.
No default. When set to 0 the metrics server is not started
func SetMiddleware ¶
SetMiddleware configures the global middleware for the HTTP router.
func SetOrganisationService ¶
func SetOrganisationService(svc *organization.Service) Option
SetOrganisationService configures the organization service.
func SetRouters ¶
func SetRouters(rb ...RouterFunc) Option
SetRouters adds all HTTP routes for the server.
func SetShutdownHook ¶ added in v0.1.8
func SetStaticFS ¶ added in v0.2.1
SetStaticFS registers an fs.FS as a static fileserver.
It is mounts '/static/*' and '/favicon.ico'. Note: it can only be set once. So you can register multiple fs.FS.
type RouterFunc ¶
RouterFunc is a callback that registers routes to the ikuzo.Server.
type Server ¶
type Server interface { ListenAndServe() error ServeHTTP(w http.ResponseWriter, r *http.Request) }
Server provides a net/http compliant WebServer.
Directories ¶
Path | Synopsis |
---|---|
Package definitions provides service definitions for oto generated service.
|
Package definitions provides service definitions for oto generated service. |
Package domain contains all Ikuzo domain models.
|
Package domain contains all Ikuzo domain models. |
driver
|
|
elasticsearch
Package elasticsearch provides a Driver for the ElasticSerach search engine.
|
Package elasticsearch provides a Driver for the ElasticSerach search engine. |
elasticsearch/elasticsearchtests
Package elasticsearchtests provides docker based integration-tests for the elasticsearch driver package.
|
Package elasticsearchtests provides docker based integration-tests for the elasticsearch driver package. |
package rdf provides tools for the Resource Description Framework (RDF), see https://www.w3.org/RDF/.
|
package rdf provides tools for the Resource Description Framework (RDF), see https://www.w3.org/RDF/. |
formats/jsonld
Package jsonld provides tools to parse and serialize RDF data in the JSON-LD format.
|
Package jsonld provides tools to parse and serialize RDF data in the JSON-LD format. |
Package render provides functionality to render responses to http.Handler and http.HandleFunc implementations.
|
Package render provides functionality to render responses to http.Handler and http.HandleFunc implementations. |
Package search provides generic functionality to query the hub3 Linked-Open-Data store.
|
Package search provides generic functionality to query the hub3 Linked-Open-Data store. |
service
|
|
x
package x contains experimental or unstable services.
|
package x contains experimental or unstable services. |
x/namespace
nolint:misspell // because namespaces often are not valid words
|
nolint:misspell // because namespaces often are not valid words |
x/oaipmh/pmh
Package provides a client and server implementation for the OAI-PMH v2.0 Protocol.
|
Package provides a client and server implementation for the OAI-PMH v2.0 Protocol. |
x/sitemap
Package sitemap provides a service to generated sitemaps
|
Package sitemap provides a service to generated sitemaps |
storage
|
|
x
package x contains experimental storage implementations.
|
package x contains experimental storage implementations. |
x/ginger
Package ginger supports integration with the Driebit Ginger platform
|
Package ginger supports integration with the Driebit Ginger platform |
x/sparqltest
package sparqltest contains a test-suite based on the W3c SPARQL workinggroup.
|
package sparqltest contains a test-suite based on the W3c SPARQL workinggroup. |
Package validator provides utilities to provide a uniform valditation experience.
|
Package validator provides utilities to provide a uniform valditation experience. |
package webapp provides shared functionality for building web applications on top of the ikuzo APIs.
|
package webapp provides shared functionality for building web applications on top of the ikuzo APIs. |