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

Mute subscriber that tries to write to closed output #1604

Closed
dzikoysk opened this issue Oct 14, 2022 · 6 comments · Fixed by #1607
Closed

Mute subscriber that tries to write to closed output #1604

dzikoysk opened this issue Oct 14, 2022 · 6 comments · Fixed by #1607
Assignees
Labels
bug Bugs & errors found in Reposilite cosmetic Issue is not harmful and affects only cosmatic part of a project good first issue It would be great, if this issue could be solved by community

Comments

@dzikoysk
Copy link
Owner

Request details

obraz

Probably caused by: https://github.com/dzikoysk/reposilite/blob/main/reposilite-backend/src/main/kotlin/com/reposilite/console/infrastructure/ConsoleWebSocketHandler.kt#L69

@dzikoysk dzikoysk added bug Bugs & errors found in Reposilite cosmetic Issue is not harmful and affects only cosmatic part of a project good first issue It would be great, if this issue could be solved by community labels Oct 14, 2022
@Anuran12
Copy link

@dzikoysk I would like to do this.. but don't know how to solve this... please guide

@dzikoysk
Copy link
Owner Author

dzikoysk commented Oct 14, 2022

I think that simple try-catch around ctx.send() for ClosedChannelException could be enough, this error is pretty random and it's hard to reproduce it, so we will just observe the result :)

@Anuran12
Copy link

I think that simple try-catch around ctx.send() for ClosedChannelException could be enough, this error is pretty random and it's hard to reproduce it, so we will just observe the result :)

Maybe I could not do it.. you better to assign someone else.. sorry to bother 😢

@P-DR0ZD
Copy link
Contributor

P-DR0ZD commented Oct 14, 2022

Can I be assigned I think I could solve it

@P-DR0ZD
Copy link
Contributor

P-DR0ZD commented Oct 14, 2022

What should be done when the exception is caught?

@dzikoysk
Copy link
Owner Author

I think we can safely mute it by just logging it at DEBUG level? 🤔

P-DR0ZD added a commit to P-DR0ZD/reposilite that referenced this issue Oct 14, 2022
P-DR0ZD added a commit to P-DR0ZD/reposilite that referenced this issue Oct 14, 2022
dzikoysk added a commit that referenced this issue Oct 15, 2022
* Added error catching as asked for in issue #1604

* Added error catching as asked for in issue #1604 Also Imported ClosedChannelException

* Codestyle

Co-authored-by: dzikoysk <dzikoysk@dzikoysk.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bugs & errors found in Reposilite cosmetic Issue is not harmful and affects only cosmatic part of a project good first issue It would be great, if this issue could be solved by community
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants