Comments (4)
An update on this issue. I am getting some failures with an issue that seems directly connected to the above SSL usage with my Kitura-based server.
When I run the server on MacOS, using self-signing certificates (and following the technique given here https://developer.ibm.com/swift/2016/09/22/securing-kitura-part-1-enabling-ssltls-on-your-swift-server/), I get the above kind of error (i.e., errSSLClosedAbort). Plus, with certain of my endpoints my call to RouterResponse's end
method blocks the server thread. This is happening specifically when I am completing a download of data using a HTTP GET. On MacOS, when the server blocks on these end
calls, the client doesn't notice-- e.g., it is not also blocked.
When I run the server on Ubuntu 16.04 Linux, I run into a similar but even more severe situation. These same end
calls tend to block the server thread, and the client side times out on these endpoint calls.
I should mention, I'm using an iOS Swift-based client with URLSession's to do the downloads and other server endpoint communication.
This is an open source project, and I could point you to the code. So far, I'm just trying to characterize the problem and haven't tried creating a simpler instance of the problem.
from kitura-net.
Further update. I've now tried this with a CA Authority signed SSL certificate (from https://letsencrypt.org). The same basic issue occurs. When I'm doing multiple successive of these in a row, the server thread blocks on a GET download of data. This is where it's failing in my server: https://github.com/crspybits/SyncServerII/blob/master/Server/Sources/Server/ServerSetup.swift#L146
I'm running the following test on my iOS client:
https://github.com/crspybits/SyncServerII/blob/master/iOS/Example/Tests/Performance.swift#L53
Also, and I'm not sure how/if this is related, I am getting lots of the error:
[2017-05-25T03:23:30.802Z] [ERROR] [HTTPServer.swift:194 listen(listenSocket:socketManager:)] Error accepting client connection: Error code: 1(0x1), ERROR: SSL_accept, code: 1, reason: Could not determine error reason.
from kitura-net.
Still having the same kind of issue, and I've detailed progress here:
https://stackoverflow.com/questions/44224048/timeout-issue-when-downloading-from-aws-ec2-to-ios-app
from kitura-net.
It looks like I've got a work-around for this issue. Take a look at Update5
on my stackoverflow post above. I still have some concerns about being able to get the server into a state where there are numerous server threads blocked. It looks like a client can cause the server to get into such a state. Any suggestions would be welcomed.
from kitura-net.
Related Issues (20)
- Implement test for ServerLifecycleListener.performClientConnectionFailCallbacks
- EXC_BAD_ACCESS when reading HTTPServerRequest.method with SwiftMetricsKitura HOT 4
- EXC_BAD_INSTRUCTION on IncomingSocketHandler.swift line 197 (only Mac OS X) HOT 7
- missing required modules: 'CCurl', 'CHTTPParser' HOT 1
- Undeprecate `urlComponents`?
- Thread sanitizer finds issues HOT 7
- Errors in removeIdleSockets HOT 8
- PATCH Request not passing Body HOT 16
- Valid port numbers not representable HOT 6
- Use ephemeral ports in KituraNet tests HOT 1
- Port Kitura Request/Response tests to Kitura-net HOT 1
- Kitura-net ignores an Expect: 100-continue header HOT 1
- Validate curl 7.59 fix for chunked encoding HOT 2
- HTTPStatusCode enum is missing registered values HOT 1
- Gracefully close connections on server shutdown
- Study: Does the HTTP smuggling attack affect Kitura-net?
- ClientRequest error. on Linux HOT 2
- Error=Parsed fewer bytes than were passed to the HTTP parser HOT 5
- How make unix domain sock http req
- Update for Swift 5.2 needed HOT 1
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 kitura-net.