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

Adding workaround for the case when a connect gets stuck forever #1

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

elruwen
Copy link

@elruwen elruwen commented Jan 4, 2016

I hope to fix twitter-archive#117 with this pull request.

I was never able to reproduce the issue in our test environment. In the end I put my change on some of the production servers and I could verify via behavior and logging that it actually fixed my problem.

This is a workaround and I guess the problem is somewhere inside netty. But since there is already a branch to move to netty 4, I don't think it is worth to track down the bug there.

PS: Currently bugs can not be reported to this project.

@elruwen
Copy link
Author

elruwen commented Jan 5, 2016

For a green build #2 needs to be merged first.

@jjlauer
Copy link
Member

jjlauer commented Jan 5, 2016

Merged your other PR - if you could fix the conflict here I'll take a look.

// It turns out that under certain unknown circumstances the connect waits forever: https://github.com/twitter/cloudhopper-smpp/issues/117
// That's why the future is canceled 1 second after the specified timeout.
// This is a workaround and hopefully not needed after the switch to netty 4.
if (!connectFuture.await(connectTimeoutMillis + 1000)) {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I originally used two minutes just to be on the safe side, but I think 1 second should do the trick. I don't want to use the same time as the real timeout in order not to interfere with the real timeout.

@elruwen
Copy link
Author

elruwen commented Feb 9, 2016

I fixed the conflict long time ago, but I forgot to comment again. Fixed ;)

l1101100 added a commit to l1101100/cloudhopper-smpp that referenced this pull request Mar 8, 2016
satanatoly added a commit to RestComm/cloudhopper-smpp that referenced this pull request Aug 7, 2017
satanatoly pushed a commit to RestComm/cloudhopper-smpp that referenced this pull request Sep 14, 2017
Fixed issue with connection being stuck on awaitUninterruptibly() as per fizzed#1
Fixed blocking issue at channel write.
Related issue RestComm/smpp-extensions#28
olenara added a commit to RestComm/cloudhopper-smpp that referenced this pull request Sep 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Threads get stuck at DefaultSmppClient.createConnectedChannel
2 participants