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

Side by Side Diff: appengine/logdog/coordinator/backend/archive.go

Issue 1672833003: LogDog: Add log rendering view. Base URL: https://github.com/luci/luci-go@master
Patch Set: Clean up, add tests, little reorg. Created 4 years, 10 months 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
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 backend 5 package backend
6 6
7 import ( 7 import (
8 "fmt" 8 "fmt"
9 "net/http" 9 "net/http"
10 "strings" 10 "strings"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 maxDelay := cfg.GetCoordinator().ArchiveDelayMax.Duration() 100 maxDelay := cfg.GetCoordinator().ArchiveDelayMax.Duration()
101 complete := !now.After(ls.Updated.Add(maxDelay)) 101 complete := !now.After(ls.Updated.Add(maxDelay))
102 if !complete { 102 if !complete {
103 log.Fields{ 103 log.Fields{
104 "path": ls.Path(), 104 "path": ls.Path(),
105 "updatedTimestamp": ls.Updated, 105 "updatedTimestamp": ls.Updated,
106 "maxDelay": maxDelay, 106 "maxDelay": maxDelay,
107 }.Warningf(c, "Log stream is past maximum archival delay. Droppi ng completeness requirement.") 107 }.Warningf(c, "Log stream is past maximum archival delay. Droppi ng completeness requirement.")
108 } 108 }
109 109
110 » st, err := b.s.Storage(c) 110 » st, err := b.s.IntermediateStorage(c)
111 if err != nil { 111 if err != nil {
112 return err 112 return err
113 } 113 }
114 defer st.Close() 114 defer st.Close()
115 115
116 gsClient, err := b.s.GSClient(c) 116 gsClient, err := b.s.GSClient(c)
117 if err != nil { 117 if err != nil {
118 return err 118 return err
119 } 119 }
120 defer func() { 120 defer func() {
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after
485 // If one of the components is empty, it will be ignored. 485 // If one of the components is empty, it will be ignored.
486 func buildGSPath(parts ...string) string { 486 func buildGSPath(parts ...string) string {
487 path := make([]string, 0, len(parts)) 487 path := make([]string, 0, len(parts))
488 for _, p := range parts { 488 for _, p := range parts {
489 if len(p) > 0 { 489 if len(p) > 0 {
490 path = append(path, p) 490 path = append(path, p)
491 } 491 }
492 } 492 }
493 return strings.Join(path, "/") 493 return strings.Join(path, "/")
494 } 494 }
OLDNEW
« no previous file with comments | « appengine/cmd/logdog_coordinator/vmuser/main.go ('k') | appengine/logdog/coordinator/backend/archive_test.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698