streams

package
v0.0.0-...-937ad84 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 23, 2024 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GlobalLogDirectory *paths.Path

GlobalLogDirectory is the directory where logs are created

Functions

func CatchAndLogPanic

func CatchAndLogPanic()

CatchAndLogPanic will recover a panic, log it on standard logger, and rethrow it to continue stack unwinding.

func LogReadWriteCloserAs

func LogReadWriteCloserAs(upstream io.ReadWriteCloser, filename string) io.ReadWriteCloser

LogReadWriteCloserAs return a proxy for the given upstream io.ReadWriteCloser that forward and logs all read/write/close operations on the given filename that is created in the GlobalLogDirectory.

func LogReadWriteCloserToFile

func LogReadWriteCloserToFile(upstream io.ReadWriteCloser, file *os.File) io.ReadWriteCloser

LogReadWriteCloserToFile return a proxy for the given upstream io.ReadWriteCloser that forward and logs all read/write/close operations on the given file.

func NewReadWriteCloser

func NewReadWriteCloser(in io.ReadCloser, out io.WriteCloser) io.ReadWriteCloser

NewReadWriteCloser create an io.ReadWriteCloser from given io.ReadCloser and io.WriteCloser.

func OpenLogFileAs

func OpenLogFileAs(filename string) *os.File

OpenLogFileAs creates a log file in GlobalLogDirectory.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL