Jeromy
bb3a75aa08
remove context from context
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2015-07-20 20:53:06 -07:00
Jeromy
f9f3c6a527
make offline commands respect timeout
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2015-07-20 14:34:16 -07:00
Tor Arne Vestbø
bfd12114e7
Remove daemon InitDone guard in interrupt handler
...
Instead of just terminating right there and then, we cancel the
context, and let the daemon exit cleanly. This make take a few
seconds, as the node builder and its child processes do not
care too much about the context state while building nodes,
but this can be improved by injecting checks for ctx.Done()
before time-consuming steps.
2015-04-20 16:35:35 +02:00
Ho-Sheng Hsiao
bf22aeec0a
Reorged imports from jbenet/go-ipfs to ipfs/go-ipfs
...
- Modified Godeps/Godeps.json by hand
- [TEST] Updated welcome docs hash to sharness
- [TEST] Updated contact doc
- [TEST] disabled breaking test (t0080-repo refs local)
2015-03-31 12:52:25 -07:00
Konstantin Koroviev
d23bed5baa
Rename ContextIsReadyToBeClosed to InitDone
2015-03-12 11:42:07 +02:00
Konstantin Koroviev
afd497e194
Dirty hack to fix race conditions in the daemon
2015-03-09 16:39:41 +02:00
Henry
86b34a2af6
NewRequest() - export OptMap type
2015-03-08 12:14:41 +01:00
Henry
92d08db7a5
rewrote import paths of go.net/context to use golang.org/x/context
...
- updated go-ctxgroup and goprocess
ctxgroup: AddChildGroup was changed to AddChild. Used in two files:
- p2p/net/mock/mock_net.go
- routing/dht/dht.go
- updated context from hg repo to git
prev. commit in hg was ad01a6fcc8a19d3a4478c836895ffe883bd2ceab. (context: make parentCancelCtx iterative)
represents commit 84f8955a887232b6308d79c68b8db44f64df455c in git repo
- updated context to master (b6fdb7d8a4ccefede406f8fe0f017fb58265054c)
Aaron Jacobs (2):
net/context: Don't accept a context in the DoSomethingSlow example.
context: Be clear that users must cancel the result of WithCancel.
Andrew Gerrand (1):
go.net: use golang.org/x/... import paths
Bryan C. Mills (1):
net/context: Don't leak goroutines in Done example.
Damien Neil (1):
context: fix removal of cancelled timer contexts from parent
David Symonds (2):
context: Fix WithValue example code.
net: add import comments.
Sameer Ajmani (1):
context: fix TestAllocs to account for ints in interfaces
2015-02-25 11:58:19 +01:00
Matt Bell
3fc9bedb0b
commands: Made Std{in|out|err} accessible in Request/Response
2015-01-23 18:29:31 -08:00
Matt Bell
4a6aec645e
commands: request: Added Values map
2015-01-23 18:29:30 -08:00
Matt Bell
7a579bbf79
commands: Moved files code into 'commands/files' subpackage
2015-01-13 22:50:53 -08:00
Brian Tiger Chow
5b3164de5c
refactor(repo/config) move config under repo
2015-01-13 03:09:30 -08:00
Juan Batiz-Benet
ddd7540186
cmds: flush output on standard readers
...
cc @mappum can we do this for the copyChunks case?
2015-01-11 20:52:33 -08:00
Matt Bell
0419ce1d20
commands: Removed unused cleanup function
2015-01-06 15:55:17 -08:00
Matt Bell
aa84f69231
commands: Added a 'Definition()' method to OptionValue to get a reference to the option definiton
2014-11-19 00:26:02 -08:00
Matt Bell
bbf3a1f4d4
commands: Changed Option to an interface
2014-11-19 00:24:55 -08:00
Juan Batiz-Benet
f43954fcd1
ensure node constructed is online for daemon
2014-11-18 05:20:04 -08:00
Matt Bell
c19bdf18b2
commands: Added Request#SetOptions
2014-11-18 02:13:57 -08:00
Matt Bell
f8be26810a
commands: Changed Request#Arguments to a []string
2014-11-18 02:13:55 -08:00
Matt Bell
bfc83bd16a
commands: Added SetArguments/SetFiles to Request
2014-11-18 02:13:54 -08:00
Matt Bell
1c8d73f9ea
commands: Added Request#Files()
2014-11-18 02:13:53 -08:00
Matt Bell
abb8374d43
commands: NewRequest: Documented error case
2014-11-17 00:00:16 -08:00
Matt Bell
5e16dfb111
commands: Improved option conversin error message
2014-11-16 18:05:13 -08:00
Matt Bell
d1c50972f5
commands: Check for option errors when constructing Requests
2014-11-16 18:01:06 -08:00
Brian Tiger Chow
5a9de188d7
fix(commands/request) return err when unable to load config/node due to
...
nil function
cc @jbenet @mappum
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:04 -08:00
Juan Batiz-Benet
d18902df27
cmds2: changed how the ctx.Node works
2014-11-14 03:20:02 -08:00
Brian Tiger Chow
7116591351
docs(commands/request)
2014-11-14 03:19:59 -08:00
Juan Batiz-Benet
49792b2362
refactored cast errors to use a util
2014-11-14 03:19:56 -08:00
Matt Bell
81dbb23602
commands: Cleanup Requests after command execution returns
2014-11-14 03:17:43 -08:00
Matt Bell
8c9ee52a93
commands: Fixed value mutation bug in Request#SetOption
2014-11-14 03:17:42 -08:00
Matt Bell
a9bd172414
commands: Fixed handling of int/uint option values
2014-11-14 03:17:38 -08:00
Matt Bell
3e507f7c9f
commands: Changed option accessor API (Request#Option now returns an OptionValue)
2014-11-14 03:17:38 -08:00
Matt Bell
20591c7e64
commands: Made SetOption override existing values (even if they used a different alias)
2014-11-14 03:17:37 -08:00
Matt Bell
eebb43753b
commands: Added list of option definitions to Request, so Option can lookup values by all aliases
2014-11-14 03:17:37 -08:00
Brian Tiger Chow
de170927ad
fix(commands/request) cast safely
...
should be able to look at a function in isolation and prove it won't
panic. if that's not possible, should cast safely.
2014-11-05 10:15:17 -08:00
Matt Bell
75649f3d49
commands: Moved argument checking into a Command method, fail early when parsing commands
2014-11-04 02:04:49 -08:00
Matt Bell
586a019fbf
commands: Fixed Request#CheckArguments not erroring when required arguments were missing
2014-11-04 02:04:49 -08:00
Matt Bell
e8d0cbff1d
commands: Check argument validity when running commands
2014-11-04 02:04:49 -08:00
Matt Bell
3a8d60cc61
commands: Removed inpout stream from Request
2014-11-04 02:04:48 -08:00
Matt Bell
827f1dd0b0
commands: Changed Request arguments to a []interface{}
2014-11-04 02:04:48 -08:00
Matt Bell
81f29257a1
commands: Gave Requests a reference to the command they are being called on
2014-11-04 02:04:46 -08:00
Matt Bell
289bce6bdb
commands: Added Request#SetContext()
2014-11-04 02:04:45 -08:00
Matt Bell
20f86c01ce
commands: Added Context() to Request
2014-11-04 02:04:45 -08:00
Matt Bell
53e1359871
commands: Silently skip unrecognized options, it should be up to the transport to decide if they cause an error
2014-11-04 02:04:44 -08:00
Matt Bell
a65c99e71e
commands: Added Request#Options so consumers can iterate through provided options
2014-11-04 02:04:44 -08:00
Matt Bell
4303dccee9
commands: Added Request#SetStream
2014-10-21 18:27:39 -07:00
Juan Batiz-Benet
d464e3d143
commands: go fmt
2014-10-21 18:16:04 -07:00
Matt Bell
c0b28dc19d
commands: Added input stream field to Request
2014-10-20 14:38:09 -07:00
Juan Batiz-Benet
b10fc2cc50
turned req + res into interfaces
2014-10-20 11:49:07 -07:00
Matt Bell
e5e121a6b1
commands: Made Request#Option also return an existence bool
2014-10-20 07:04:54 -07:00