Brian Picciano
8db9e78e08
mcfg: add WithFloat64 and WithRequiredFloat64
5 years ago
Brian Picciano
f4ad383c4a
m: have log level depend on the kind of Context is being used (process or service)
5 years ago
Brian Picciano
507c359997
mcfg: modify WithCLITail to allow modifying the Usage description
5 years ago
Brian Picciano
99387d89ac
mcfg: don't allow for empty sub-command, as that makes printing help weird
5 years ago
Brian Picciano
b35b44eb22
mcfg: implement WithCLISubCommand
5 years ago
Brian Picciano
2eb4a37533
mcfg: make Parse and Populate return a Context, to allow for sub-commands
5 years ago
Brian Picciano
c0afa3d126
mcfg: Parse now takes a Context, which allows for implementing WithCLITail
5 years ago
Brian Picciano
a596306d9e
mcfg: made SourceCLI and SourceEnv be pointers
5 years ago
Brian Picciano
7752b569c3
m: add ProcessContext and rework where configuration comes from a bit
5 years ago
Brian Picciano
ea72c49935
mcfg: implement SourceCLI.TailCallback (though I'm not convinced about the naming or necessity of it)
5 years ago
Brian Picciano
f5cea76cb7
mtest/massert: rename a bunch of functions
5 years ago
Brian Picciano
2496b170d8
mtest/massert: ensure that values being asserted are captured at the moment the assertion is made
5 years ago
Brian Picciano
2343bda42a
m: add log message in Start once the start hooks have finished
5 years ago
Brian Picciano
3d939a1e80
mrun: fix bug in retrieving set of hooks/children from a context, and simplify the logic a bit
5 years ago
Brian Picciano
015edcd69a
mnet: fix PacketConn closing
5 years ago
Brian Picciano
a52230b972
mnet: fix PacketConn support again
5 years ago
Brian Picciano
5bd3bf1d6d
mnet: fix PacketConn support
5 years ago
Brian Picciano
14de888300
mnet: use ListenerOpts pattern
5 years ago
Brian Picciano
4536db8968
merr: refactor Wrap/WrapSkip/New to take multiple contexts rather than annotations
5 years ago
Brian Picciano
4303da03cc
merr/mctx: move stack code into merr
5 years ago
Brian Picciano
553a4854ea
mrun: change WithThread to WithThreads
5 years ago
Brian Picciano
dc57aadb54
m: don't log before populating params
5 years ago
Brian Picciano
dd7bc43cf8
m: rename Start to StartWaitStop, Start is a different function which only populates config and runs start hooks
5 years ago
Brian Picciano
3aa69c5878
mdb/msql: add SQL.Context method
5 years ago
Brian Picciano
604da54903
mdb/msql: implement basic MySQL connector
5 years ago
Brian Picciano
12bddbf108
add go.mod file to the project
5 years ago
Brian Picciano
e1e52db208
refactor everything to use context's annotation system, making some significant changes to annotations themselves along the way
5 years ago
Brian Picciano
000a57689d
mctx: implement beginnings of Annotations functionality
5 years ago
Brian Picciano
4b446a0efc
mctx: refactor so that contexts no longer carry mutable data
...
This change required refactoring nearly every package in this project,
but it does a lot to simplify mctx and make other code using it easier
to think about.
Other code, such as mlog and mcfg, had to be slightly modified for this
change to work as well.
5 years ago
Brian Picciano
0c2c49501e
mctx: refactor implementation of Context to not use a state stored as a value, but to just wrap a context.Context
5 years ago
Brian Picciano
5dc8d92987
mdb/mpubsub: refactor to use new mctx/mlog/mcfg stuff
5 years ago
Brian Picciano
8ddf1348db
mdb/mdatastore: refactor to use new mctx/mlog/mcfg stuff
5 years ago
Brian Picciano
40794d83b8
mdb/mbigtable: refactor to use new mctx/mlog/merr stuff
5 years ago
Brian Picciano
a5446b0833
mdb/mbigquery: refactor to use new mctx/mlog/merr stuff
5 years ago
Brian Picciano
608eb90274
mdb: refactor to use new mctx stuff
5 years ago
Brian Picciano
f783b62f6f
mtest: implement NewCtx and Run, and use them in mnet and mhttp's tests
5 years ago
Brian Picciano
c6e29715b0
merr: implement WithKV
5 years ago
Brian Picciano
526639041b
mnet: make sure listen-addr param's usage starts with uppercase
5 years ago
Brian Picciano
f02f2904b0
mcfg: ensure all usages end in a period when printing help to cli
5 years ago
Brian Picciano
6adfbdbcfb
m: implement NewServiceCtx, use it in totp-proxy
5 years ago
Brian Picciano
15b84cb173
mlog: implement LevelFromString
5 years ago
Brian Picciano
20c6f95091
mlog: refactor to use Clone/Set instead of With pattern, implement CtxSetAll
5 years ago
Brian Picciano
5bd0790f6e
mctx: implement BreadthFirstVisit
5 years ago
Brian Picciano
8e2cffd65b
mcfg: make ParamValue not embed Param, so that a Source which is []ParamValue makes sense, and can replace SourceMap
5 years ago
Brian Picciano
ddd26259b2
merr: make New take in optional key/value pairs for convenience
5 years ago
Brian Picciano
b33b157e15
mcfg: update docs to make running Populate more than once explicitly allowed
5 years ago
Brian Picciano
a24262f295
mlog: update function docs
5 years ago
Brian Picciano
e9416dbe2a
mlog: update package doc example
5 years ago
Brian Picciano
79bf3d6f89
totp-proxy: update to use new mctx/mcfg/mrun framework
5 years ago
Brian Picciano
a00a268256
m: implement Run function, which glues together mcfg.Populate, mrun.Start, and mrun.Stop
5 years ago