Commit e122e44d authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent ce93805c
......@@ -266,12 +266,16 @@ func (c *Client) flushEventq0() {
// Sync implements zodb.IStorageDriver.
func (c *Client) Sync(ctx context.Context) (head zodb.Tid, err error) {
ctx = taskctx.Runningf(ctx, "%s: zsync", c.node.MyInfo.NID)
if glog.V(2) {
task.TraceBegin(ctx)
defer func() { task.TraceEnd(ctx, err) }()
}
defer func() {
if err != nil {
err = &zodb.OpError{URL: c.URL(), Op: "sync", Args: nil, Err: err}
}
}()
// defer task.Runningf(&ctx, "%s: zsync", c.nid)(&err) ... // XXX enable
err = c.node.WithOperational(ctx, func(mlink *neonet.NodeLink, _ *xneo.ClusterState) error {
// XXX mlink can become down while we are making the call.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment