common/

directory
v3.11.0+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 27, 2017 License: Apache-2.0, Apache-2.0

Directories

Path Synopsis
db
gin
Some convenient utility for usage of gin framework JSON service ginConfig := &GinConfig{ Mode: gin.ReleaseMode, Host: "localhost", Port: 8080, } engine := NewDefaultJsonEngine(ginConfig) // Start service // StartServiceOrExit(engine, ginConfig) // Binds the engine into existing HTTP service http.Handle("/root-service", engine) Panic in Code By using of "NewDefaultJsonEngine()", any panic code would be output as: { "http_status": 500, "error_code": -1, "error_message": fmt.Sprintf("%v", panicObject), } And the HTTP engine would keep running.
Some convenient utility for usage of gin framework JSON service ginConfig := &GinConfig{ Mode: gin.ReleaseMode, Host: "localhost", Port: 8080, } engine := NewDefaultJsonEngine(ginConfig) // Start service // StartServiceOrExit(engine, ginConfig) // Binds the engine into existing HTTP service http.Handle("/root-service", engine) Panic in Code By using of "NewDefaultJsonEngine()", any panic code would be output as: { "http_status": 500, "error_code": -1, "error_message": fmt.Sprintf("%v", panicObject), } And the HTTP engine would keep running.
Because go language does not have industrial level of exception handing mechanism, using the information of calling state is the only way to expose secret in code.
Because go language does not have industrial level of exception handing mechanism, using the information of calling state is the only way to expose secret in code.
service
This package provides lazy-loading and postfix binding for text building.
This package provides lazy-loading and postfix binding for text building.
This package provides out-of-box conversion service.
This package provides out-of-box conversion service.
This package provides misc utilities.
This package provides misc utilities.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL