Documentation ¶
Overview ¶
Package uds
Package uds ¶
Package uds ¶
Package uds ¶
Package uds ¶
Package uds ¶
Package uds
Index ¶
Constants ¶
View Source
const ( ErrUnsupportedOperation = "unsupported operation" ErrUdsListenerNil = "unix server listener is nil" )
Variables ¶
View Source
var AutoCheckOption = Option{ AutoCheck: true, AutoCheckDuration: 60, AutoRecover: false, ResponseFormat: Res{}, RequestFormat: Req{}, MaxSize: 1 << 10, LogTrace: true, }
Functions ¶
func CreateSocket ¶
CreateSocket 创建socket 默认监听时会创建遇到无权限时调用此方法创建 s app or app.socket
Types ¶
type Logger ¶
type Logger interface { Info(v ...interface{}) Warn(v ...interface{}) Error(v ...interface{}) InfoF(fmt string, v ...interface{}) WarnF(fmt string, v ...interface{}) ErrorF(fmt string, v ...interface{}) }
Logger 自定义的日志记录器 实现接口即可
type UDSServer ¶
type UDSServer struct { Name string // 注册服务的名称 Option Option // 默认使用fushin option Logger Logger // 默认使用fushin logger // contains filtered or unexported fields }
func NewWithOption ¶
NewWithOption 返回自定义的unix server
Source Files ¶
Click to show internal directories.
Click to hide internal directories.