Open Maxi-Mega opened 2 years ago
On a related note, the logging library github.com/go-logr/logr
is now on v1
(no longer v0
) which broke the build when I naively updated my transient dependencies 😅
@R167 github.com/go-logr/logr dependency is now updated in the new release
I have two suggestions regarding the logging of the Gate proxy:
- It would be nice to have the possibility to choose what we want in the logs. For example, in production I don't think the path of the file and the line from which the logger was called is any useful information. Maybe the ability to choose the format of the date would be interesting too, for instance if we want to be able to process the logs with an other application... which leads us to the second point.
- Save the logs to a file, like any regular Minecraft proxy or server. For now, the only way I found to do that is to redirect manually the program outputs to a file like so:
./gate > logs.txt 2>&1
, but color codes are not supported and render like this:�[34m
.Thanks for your reading
Hello, you can always make use of https://github.com/minekube/gate/blob/ee91199b2b7e44f385c873601dcaf30a100ae7be/pkg/runtime/logr/log.go#L45
Or setup a Gate instance specifying your own Logger https://github.com/minekube/gate/blob/ee91199b2b7e44f385c873601dcaf30a100ae7be/pkg/gate/gate.go#L37
I have two suggestions regarding the logging of the Gate proxy:
./gate > logs.txt 2>&1
, but color codes are not supported and render like this:[34m
.Thanks for your reading