constellation/bootstrapper/internal/logging/logger.go
Daniel Weiße 690b50b29d
dev-docs: Go package docs (#958)
* Remove unused package

* Add Go package docs to most packages

Signed-off-by: Daniel Weiße <dw@edgeless.systems>
Signed-off-by: Fabian Kammel <fk@edgeless.systems>
Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
Co-authored-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
Co-authored-by: Fabian Kammel <fk@edgeless.systems>
2023-01-19 15:57:50 +01:00

33 lines
886 B
Go

/*
Copyright (c) Edgeless Systems GmbH
SPDX-License-Identifier: AGPL-3.0-only
*/
// Package logging provides an interface for logging information to a non-confidential destination
package logging
import "io"
// CloudLogger is used to log information to a **non-confidential** destination
// at cloud provider for early-boot debugging. Make sure to **NOT** include any
// sensitive information!
type CloudLogger interface {
// Disclose is used to log information into a **non-confidential** destination at
// cloud provider for early-boot debugging. Make sure to **NOT** Disclose any
// sensitive information!
Disclose(msg string)
io.Closer
}
// NopLogger implements CloudLogger interface, but does nothing.
type NopLogger struct{}
// Disclose does nothing.
func (l *NopLogger) Disclose(msg string) {}
// Close does nothing.
func (l *NopLogger) Close() error {
return nil
}