Skip to content

Commit 6baff16

Browse files
committed
log: add package documentation and summary of package's purpose
Add a package doc to (try to) describe the purpose of this package, and to describe the purpose (and expectations) of aliases provided by the package. > Package log provides types and functions related to logging, passing > loggers through a context, and attaching context to the logger. > > # Transitional types > > This package contains various types that are aliases for types in [logrus]. > These aliases are intended for transitioning away from hard-coding logrus > as logging implementation. Consumers of this package are encouraged to use > the type-aliases from this package instead of directly using their logrus > equivalent. > > The intent is to replace these aliases with locally defined types and > interfaces once all consumers are no longer directly importing logrus > types. > > IMPORTANT: due to the transitional purpose of this package, it is not > guaranteed for the full logrus API to be provided in the future. As > outlined, these aliases are provided as a step to transition away from > a specific implementation which, as a result, exposes the full logrus API. > While no decisions have been made on the ultimate design and interface > provided by this package, we do not expect carrying "less common" features. Signed-off-by: Sebastiaan van Stijn <[email protected]>
1 parent 238da2c commit 6baff16

1 file changed

Lines changed: 21 additions & 0 deletions

File tree

log/context.go

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,27 @@
1414
limitations under the License.
1515
*/
1616

17+
// Package log provides types and functions related to logging, passing
18+
// loggers through a context, and attaching context to the logger.
19+
//
20+
// # Transitional types
21+
//
22+
// This package contains various types that are aliases for types in [logrus].
23+
// These aliases are intended for transitioning away from hard-coding logrus
24+
// as logging implementation. Consumers of this package are encouraged to use
25+
// the type-aliases from this package instead of directly using their logrus
26+
// equivalent.
27+
//
28+
// The intent is to replace these aliases with locally defined types and
29+
// interfaces once all consumers are no longer directly importing logrus
30+
// types.
31+
//
32+
// IMPORTANT: due to the transitional purpose of this package, it is not
33+
// guaranteed for the full logrus API to be provided in the future. As
34+
// outlined, these aliases are provided as a step to transition away from
35+
// a specific implementation which, as a result, exposes the full logrus API.
36+
// While no decisions have been made on the ultimate design and interface
37+
// provided by this package, we do not expect carrying "less common" features.
1738
package log
1839

1940
import (

0 commit comments

Comments
 (0)