Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(172)

Side by Side Diff: common/logdog/butlerproto/proto.go

Issue 1211053004: LogDog: Add Butler Output package. (Closed) Base URL: https://github.com/luci/luci-go@logdog-review-streamserver
Patch Set: Relocate butlerproto to common, document. Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « common/logdog/butlerproto/doc.go ('k') | common/logdog/butlerproto/proto_test.go » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package butlerproto 5 package butlerproto
6 6
7 import ( 7 import (
8 "bytes" 8 "bytes"
9 "compress/zlib" 9 "compress/zlib"
10 "errors" 10 "errors"
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 238
239 // WriteWith writes a ButlerLogBundle to the supplied recordio.Writer. 239 // WriteWith writes a ButlerLogBundle to the supplied recordio.Writer.
240 func (w *Writer) WriteWith(fw recordio.Writer, b *protocol.ButlerLogBundle) erro r { 240 func (w *Writer) WriteWith(fw recordio.Writer, b *protocol.ButlerLogBundle) erro r {
241 data, err := proto.Marshal(b) 241 data, err := proto.Marshal(b)
242 if err != nil { 242 if err != nil {
243 return fmt.Errorf("butlerproto: failed to marshal Bundle: %s", b ) 243 return fmt.Errorf("butlerproto: failed to marshal Bundle: %s", b )
244 } 244 }
245 245
246 return w.writeData(fw, protocol.ButlerMetadata_ButlerLogBundle, data) 246 return w.writeData(fw, protocol.ButlerMetadata_ButlerLogBundle, data)
247 } 247 }
OLDNEW
« no previous file with comments | « common/logdog/butlerproto/doc.go ('k') | common/logdog/butlerproto/proto_test.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698