From bee37d1f1af0a7cc1420c585d13bddac93a3ee1d Mon Sep 17 00:00:00 2001 From: dmitri Date: Wed, 9 Dec 2020 13:23:09 +0100 Subject: [PATCH] Address review comments --- lib/reversetunnel/srv.go | 1 + lib/services/server.go | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/lib/reversetunnel/srv.go b/lib/reversetunnel/srv.go index 5d7a9ee3b7914..0b9553f7d35b4 100644 --- a/lib/reversetunnel/srv.go +++ b/lib/reversetunnel/srv.go @@ -183,6 +183,7 @@ type Config struct { // Component is a component used in logs Component string + // Log specifies the logger Log log.FieldLogger // FIPS means Teleport was started in a FedRAMP/FIPS 140-2 compliant diff --git a/lib/services/server.go b/lib/services/server.go index 575a01c92dd8a..c6213a17fa498 100644 --- a/lib/services/server.go +++ b/lib/services/server.go @@ -382,6 +382,11 @@ func (s *ServerV2) DeepCopy() Server { // Merge overwrites r from src and // is part of support for cloning Server values // using proto.Clone. +// +// Note: this does not implement the full Merger interface, +// specifically, it assumes that r is zero value. +// See https://github.com/gogo/protobuf/blob/v1.3.1/proto/clone.go#L58-L60 +// // Implements proto.Merger func (r *Rotation) Merge(src proto.Message) { s, ok := src.(*Rotation) @@ -394,6 +399,11 @@ func (r *Rotation) Merge(src proto.Message) { // Merge overwrites r from src and // is part of support for cloning Server values // using proto.Clone. +// +// Note: this does not implement the full Merger interface, +// specifically, it assumes that r is zero value. +// See https://github.com/gogo/protobuf/blob/v1.3.1/proto/clone.go#L58-L60 +// // Implements proto.Merger func (r *Metadata) Merge(src proto.Message) { m, ok := src.(*Metadata)