Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consistent logging API across the appservice and web apis. #422

Open
Gnuxie opened this issue Nov 15, 2022 · 1 comment
Open

Consistent logging API across the appservice and web apis. #422

Gnuxie opened this issue Nov 15, 2022 · 1 comment
Labels
A-Appservice T-Task Refactoring, enabling or disabling functionality, other engineering tasks

Comments

@Gnuxie
Copy link
Contributor

Gnuxie commented Nov 15, 2022

Currently logging is split between mjolnir.logMessage, LogService.log (etc) and console.log. There might even be more inconsistencies given no doubt matrix-appservice-bridge will also bring its own way to log messages and errors.

@Gnuxie Gnuxie added T-Task Refactoring, enabling or disabling functionality, other engineering tasks A-Appservice labels Nov 15, 2022
@Gnuxie
Copy link
Contributor Author

Gnuxie commented Nov 30, 2022

Now that we depend on matrix-appservice-bridge, we can use their new Logger as seen in matrix-hookshot https://github.com/matrix-org/matrix-hookshot/pull/488/files. And to be extra clear, we can use this regardless of whether mjolnir is being operated in bot or appservice mode.

Gnuxie added a commit that referenced this issue Nov 30, 2022
#422
Haven't changed all of the mjolnir components to use this,
just the appservice.
The fact that we've configured this properly means we get
logging from matrix-appservice-bridge components too (we didn't before).
Gnuxie added a commit that referenced this issue Nov 30, 2022
#422
Haven't changed all of the mjolnir components to use this,
just the appservice.
The fact that we've configured this properly means we get
logging from matrix-appservice-bridge components too (we didn't before).
Gnuxie added a commit that referenced this issue Nov 30, 2022
#422
Haven't changed all of the mjolnir components to use this,
just the appservice.
The fact that we've configured this properly means we get
logging from matrix-appservice-bridge components too (we didn't before).
Gnuxie added a commit that referenced this issue Nov 30, 2022
* upgrade to matrix-appservice-bridge 8.0.0

this is so we can use their new logger

* Configure and use matrix-appservice-bridge's `Logger`

#422
Haven't changed all of the mjolnir components to use this,
just the appservice.
The fact that we've configured this properly means we get
logging from matrix-appservice-bridge components too (we didn't before).

* use try/catch instead
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Appservice T-Task Refactoring, enabling or disabling functionality, other engineering tasks
Projects
None yet
Development

No branches or pull requests

1 participant