Comments (10)
I have struggled the same issue after erlang/otp 17.1.
from ranch.
If the listening socket got closed, we need to reopen it, therefore we crash here so the error bubbles up the supervision tree until the code that reopens the socket.
The relevant mailing list discussion can be found at http://erlang.org/pipermail/erlang-questions/2014-October/081183.html
This code should not be triggered on shutdown as these processes are brutally killed.
The issue comes from the application start/stop order. If you make Ranch depend on SSL, everything works correctly. What I am unsure of is what has changed that makes code that worked before 17.1 to suddenly stop working, though.
from ranch.
Thank you for the clarification. I think this issue can be closed.
from ranch.
I will keep it open for now as I need to investigate further, so this will be my reminder. Thanks for the report!
from ranch.
Hi @essen ,
How do I make Ranch depend on SSL to it prevents the crash on stop?
from ranch.
sed is your friend.
I do this:
include erlang.mk
deps::
sed -i 's/\(stdlib\)$$/\1,\n\t\tssl/' deps/ranch/ebin/ranch.app
from ranch.
Awesome, thanks for that tip
from ranch.
Hi, after erlang upgrade to r18 I have this issue again. Proposed solution with sed has no effect.
from ranch.
Fixed sed command:
sed -i 's/\(stdlib\)/\1,\t\tssl/' deps/ranch/ebin/ranch.app
from ranch.
So this is fixed in my local copy. Push later and will be in 1.3.0. Closing, thanks!
from ranch.
Related Issues (20)
- Add more Concuerror tests
- How can gen_tcp be configured to support both IPv4 and IPv6 connections HOT 4
- Supervisor protocol process cannot be stopped when connection is closed (connection_type=supervisor). HOT 15
- Upgrading from 1.4 to 2.0 HOT 5
- Release Ranch 1.8 that is compatible with OTP-24 HOT 15
- Ranch 1.7, issues upgrading a tcp to ssl/tls connection HOT 7
- Add hex metadata to Ranch master HOT 1
- Add a function that converts from ProxyInfo to ssl:connection_information/1 return value HOT 2
- using gen_tcp new interface inet_backend socket cann't listen multiple sockets in one port HOT 6
- remove the socket file before the listen and change_mode the socket file right after listen HOT 14
- Update appup for 2.1.0 HOT 3
- Proxy protocol unique ID TLV type HOT 1
- The user guide links on the README are broken HOT 1
- Password should be blanked instead of logged on error HOT 1
- TLS 1.3 connection with client verification always successful HOT 1
- ranch:handshake(Ref) silently drops invalid TLS connections in ranch_ssl via exit(normal) HOT 16
- Questions about "gen_tcp:accept/2" and "num_acceptors" HOT 2
- ranch:stop_listener/1 throws error HOT 2
- {error, no_cert} with `certs_keys` from OTP 25 HOT 8
- Issue when using DTLS HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ranch.