MCPcopy Create free account

hub / github.com/daoshenzzg/go-web-demo / functions

Functions418 in github.com/daoshenzzg/go-web-demo

↓ 33 callersMethodAppendByte
AppendByte writes a single byte to the Buffer.
library/log/internal/core/buffer.go:20
↓ 31 callersMethodClose
Close middleware
library/log/handler.go:60
↓ 22 callersMethodCode
Code get error code.
library/ecode/ecode.go:38
↓ 22 callersFunctionError
Error logs a message at the error log level.
library/log/log.go:108
↓ 15 callersMethodError
sometimes Error return Code in string form NOTE: don't use Error in monitor report even it also work for now
library/ecode/ecode.go:36
↓ 15 callersMethodLen
Len returns the length of the underlying byte slice.
library/log/internal/core/buffer.go:52
↓ 15 callersFunctionslowLog
(statement string, now time.Time)
library/database/sql/sql.go:493
↓ 14 callersMethodJSON
JSON serializes the given struct as JSON into the response body. It also sets the Content-Type as "application/json".
library/render/render.go:32
↓ 14 callersMethodLog
Log handle log variadic D is k-v struct represent log content
library/log/handler.go:53
↓ 13 callersMethodSet
Set sets the value of the named command-line flag. format: -log.filter key1,key2
library/log/log.go:90
↓ 13 callersFunctionadd
(code int, message string)
library/ecode/ecode.go:23
↓ 13 callersMethodaddKey
(key string)
library/log/internal/core/json_encoder.go:310
↓ 12 callersMethodShrink
Shrink will decrease the duration by comparing with context's timeout duration and return new timeout\context\CancelFunc.
library/time/time.go:50
↓ 12 callersMethodaddElementSeparator
()
library/log/internal/core/json_encoder.go:321
↓ 11 callersMethodAppendString
(string)
library/log/internal/core/encoder.go:121
↓ 11 callersMethodDo
Do sends an HTTP request and returns an HTTP json response.
library/net/http/client.go:199
↓ 11 callersMethodString
String implementation.
library/log/level.go:27
↓ 10 callersMethodBytes
Bytes returns a mutable reference to the underlying byte slice.
library/log/internal/core/buffer.go:62
↓ 10 callersFunctionNew
New create a new gin Context
library/render/render.go:14
↓ 10 callersFunctioncannotConvert
(d reflect.Value, s interface{})
library/cache/redis/scan.go:36
↓ 9 callersMethodReset
Reset resets the underlying byte slice. Subsequent writes re-use the slice's backing array.
library/log/internal/core/buffer.go:73
↓ 8 callersMethodGet
Get issues a GET to the specified URL.
library/net/http/client.go:138
↓ 8 callersFunctionKVString
KVString construct Field with string value.
library/log/field.go:15
↓ 8 callersFunctionNewGroup
NewGroup new a breaker group container, if conf nil use default conf.
library/net/netutil/breaker/breaker.go:65
↓ 8 callersMethodQuery
Query executes a query that returns rows, typically a SELECT. The args are for any placeholder parameters in the query.
library/database/sql/sql.go:179
↓ 8 callersMethodWrite
Write implements io.Writer.
library/log/internal/core/buffer.go:78
↓ 7 callersMethodAppendInt64
(val int64)
library/log/internal/core/json_encoder.go:208
↓ 7 callersMethodGet
Get retrieves a Buffer from the pool, creating one if necessary.
library/log/internal/core/pool.go:23
↓ 7 callersFunctionNew
New FileWriter A FileWriter is safe for use by multiple goroutines simultaneously.
library/log/internal/filewriter/filewriter.go:125
↓ 7 callersMethodWrite
Write write data to log file, return write bytes is pseudo just for implement io.Writer.
library/log/internal/filewriter/filewriter.go:193
↓ 7 callersFunctionkeyFactory
(key string)
library/log/pattern.go:105
↓ 6 callersMethodAppendUint64
(val uint64)
library/log/internal/core/json_encoder.go:242
↓ 6 callersMethodDial
Dial creates a client connection to the given target.
library/net/rpc/client.go:149
↓ 6 callersFunctionMaxSize
MaxSize set max size for single log file, defult 1GB, 0 meaning unlimit.
library/log/internal/filewriter/option.go:56
↓ 6 callersMethodMessage
Message get code message.
library/ecode/ecode.go:40
↓ 6 callersFunctionNew
New new a ecode.Codes by int value. NOTE: ecode must unique in global, the New will check repeat and then panic.
library/ecode/ecode.go:16
↓ 6 callersMethodPut
Put put a grpc ClientConn into Pool
library/net/rpc/pool.go:32
↓ 6 callersMethodUse
Use attachs a global inteceptor to the Client. For example, this is the right place for a circuit breaker or error management inteceptor.
library/net/rpc/client.go:104
↓ 6 callersFunctionValues
Values is a helper that converts an array command reply to a []interface{}. If err is not equal to nil, then Values returns nil, err. Otherwise, Value
library/cache/redis/reply.go:233
↓ 6 callersFunctionrealURL
realUrl return url with http://host/params.
library/net/http/client.go:214
↓ 5 callersMethodAddString
(key, value string)
library/log/internal/core/encoder.go:34
↓ 5 callersMethodAddUint64
(key string, val uint64)
library/log/internal/core/json_encoder.go:151
↓ 5 callersMethodAppendFloat
AppendFloat appends a float to the underlying buffer. It doesn't quote NaN or +/- Inf.
library/log/internal/core/buffer.go:47
↓ 5 callersFunctionNewClient
NewClient returns a new blank Client instance with a default client interceptor. opt can be used to add rpc dial options.
library/net/rpc/client.go:129
↓ 5 callersMethodNewRequest
NewRequest new http request with method, uri, values and headers.
library/net/http/client.go:120
↓ 4 callersMethodAdd
Add returns the result of appending value to args.
library/cache/redis/scan.go:489
↓ 4 callersMethodAddInt64
(key string, val int64)
library/log/internal/core/json_encoder.go:109
↓ 4 callersMethodAppendInt
(int)
library/log/internal/core/encoder.go:116
↓ 4 callersMethodExec
Exec executes a query without returning any rows. The args are for any placeholder parameters in the query.
library/database/sql/sql.go:157
↓ 4 callersFunctionInfo
Info logs a message at the info log level.
library/log/log.go:98
↓ 4 callersMethodJSON
JSON sends an HTTP request and returns an HTTP json response.
library/net/http/client.go:156
↓ 4 callersFunctionNewPool
NewPool constructs a new Pool.
library/log/internal/core/pool.go:11
↓ 4 callersMethodPrepare
Prepare creates a prepared statement for later queries or executions. Multiple queries or executions may be run concurrently from the returned stateme
library/database/sql/sql.go:165
↓ 4 callersMethodSayHello
SayHello implements helloworld.GreeterServer
library/net/rpc/client_test.go:22
↓ 4 callersMethodSetConfig
SetConfig set client config.
library/net/http/client.go:92
↓ 4 callersFunctionString
String parse code string to error.
library/ecode/ecode.go:65
↓ 4 callersMethodString
String returns a string copy of the underlying byte slice.
library/log/internal/core/buffer.go:67
↓ 4 callersFunctionWarn
Warn logs a message at the warning log level.
library/log/log.go:103
↓ 4 callersFunctionconvertAssignValue
(d reflect.Value, s interface{})
library/cache/redis/scan.go:116
↓ 4 callersFunctionnewPatternRender
newPatternRender new pattern render
library/log/pattern.go:34
↓ 3 callersMethodAddDuration
(key string, value time.Duration)
library/log/internal/core/encoder.go:26
↓ 3 callersMethodAddInt64
(key string, value int64)
library/log/internal/core/encoder.go:30
↓ 3 callersMethodAddUint64
(key string, value uint64)
library/log/internal/core/encoder.go:37
↓ 3 callersMethodAppendBool
Built-in types.
library/log/internal/core/encoder.go:110
↓ 3 callersMethodAppendUint
(uint)
library/log/internal/core/encoder.go:122
↓ 3 callersMethodCap
Cap returns the capacity of the underlying byte slice.
library/log/internal/core/buffer.go:57
↓ 3 callersFunctionCause
Cause cause from error to ecode.
library/ecode/ecode.go:78
↓ 3 callersMethodClose
Close close all pool conns
library/net/rpc/pool.go:66
↓ 3 callersMethodDialAll
DialAll dial grpc conns
library/net/rpc/pool.go:54
↓ 3 callersMethodDo
Warped name with namespace for Hystrix DO.
library/net/netutil/breaker/breaker.go:93
↓ 3 callersMethodEncode
EncodeEntry encodes an entry and fields, along with any accumulated context, into a byte buffer and returns it.
library/log/internal/core/encoder.go:164
↓ 3 callersFunctionMaxFile
MaxFile default 999, 0 meaning unlimit. TODO: don't create file list if MaxSize is unlimt.
library/log/internal/filewriter/option.go:48
↓ 3 callersFunctionNewClient
NewClient new a http client pool
library/net/http/client.go:60
↓ 3 callersFunctionNewPool
NewPool NewPool
library/net/rpc/pool.go:23
↓ 3 callersMethodReload
Reload reload the group by specified config, this may let all inner breaker reset to a new one.
library/net/netutil/breaker/breaker.go:82
↓ 3 callersMethodRender
(io.Writer, map[string]interface{})
library/log/pattern.go:14
↓ 3 callersFunctionToECode
(gst *status.Status)
library/net/rpc/status/status.go:34
↓ 3 callersMethodUnmarshalText
UnmarshalText unmarshal text to duration.
library/time/time.go:40
↓ 3 callersFunctionensureLen
(d reflect.Value, n int)
library/cache/redis/scan.go:28
↓ 3 callersFunctionlogw
(args []interface{})
library/log/log.go:175
↓ 3 callersFunctionstructSpecForType
(t reflect.Type)
library/cache/redis/scan.go:328
↓ 3 callersFunctiontStartSrv
()
library/net/http/client_test.go:25
↓ 3 callersFunctiontouch
(dir, name string)
library/log/internal/filewriter/filewriter_test.go:16
↓ 3 callersMethodwrite
(p []byte)
library/log/internal/filewriter/filewriter.go:327
↓ 2 callersMethodAddFloat32
(key string, value float32)
library/log/internal/core/encoder.go:28
↓ 2 callersMethodAddFloat64
(key string, value float64)
library/log/internal/core/encoder.go:27
↓ 2 callersMethodAddInt
(key string, value int)
library/log/internal/core/encoder.go:29
↓ 2 callersMethodAddTime
(key string, value time.Time)
library/log/internal/core/encoder.go:35
↓ 2 callersMethodAddUint
(key string, value uint)
library/log/internal/core/encoder.go:36
↓ 2 callersMethodAppendComplex128
(val complex128)
library/log/internal/core/json_encoder.go:184
↓ 2 callersMethodFree
Free returns the Buffer to its Pool. Callers must not retain references to the Buffer after calling Free.
library/log/internal/core/buffer.go:95
↓ 2 callersMethodGetConn
GetConn get conns from pool
library/net/rpc/pool.go:44
↓ 2 callersFunctionInt
Int parse code int to error.
library/ecode/ecode.go:62
↓ 2 callersFunctionKV
KV return a log kv for logging field. NOTE: use KV{type name} can avoid object alloc and get better performance. []~( ̄▽ ̄)~*干杯
library/log/field.go:56
↓ 2 callersFunctionNewStdout
NewStdout create a stdout log middleware
library/log/stdout.go:20
↓ 2 callersMethodRaw
Raw sends an HTTP request and returns bytes response
library/net/http/client.go:171
↓ 2 callersMethodRollback
Rollback aborts the transaction.
library/database/sql/sql.go:424
↓ 2 callersFunctionScanSlice
ScanSlice scans src to the slice pointed to by dest. The elements the dest slice must be integer, float, boolean, string, struct or pointer to struct
library/cache/redis/scan.go:412
↓ 2 callersMethodSetFormat
SetFormat set render format on log output see StdoutHandler.SetFormat for detail
library/log/handler.go:57
↓ 2 callersFunctionString
String is a helper that converts a command reply to a string. If err is not equal to nil, then String returns "", err. Otherwise String converts the r
library/cache/redis/reply.go:150
next →1–100 of 418, ranked by callers