Comments (3)
As you've pointed out @ridicoulous, because HTTP 1.1 is used the default is keep-alive anyway. With your PR changes of reusing the HttpClient it should now also be able to actually re-use the connection when making a second request.
As far is I could see there is no notable performance difference (tested some requests to Binance). The consumed time per request is mainly waiting for the server to serve up the data, not making the connection.
from cryptoexchange.net.
I've tried setting the Connection header to both Close and KeepAlive, but I've seen no timing difference between the two. If you can show me any data which suggests a performance improvement when setting the header I'll be happy to change it.
from cryptoexchange.net.
@nikkozp
I solved it via overriding ConstructRequest method in my RestClient implementation.
@JKorf requests with keep alive header should reuse existing connection, instead opening new (what can took at least 30-35ms). But according to msdn, keep alive connection is used by default if you uses HTTP 1.1
May be you didn't see any diffrenece, cause your server send Close header in responses?
from cryptoexchange.net.
Related Issues (20)
- Error converting IEnumerable<T> in Result.Error
- Info - CalculateAverageFillPrice by asset quote HOT 1
- Adding a new symbol to a existing subscribtion HOT 3
- unsafe access to subscriptions collection on SocketConnection.ProcessReconnectAsync HOT 2
- request for new common features - withdraw HOT 1
- CallResult Error code is null on request timed out HOT 1
- Proposal: Ability for all Error derived classes to have Code and Data HOT 1
- Remove the ArrayConverter and Cache the New Expressions instead of using Activator.CreateInstance
- It is not possible to change ratelimiters after instantiating the REST client. HOT 2
- Exception "Value cannot be null" in RestApiClient.ParseRateLimitResponse HOT 1
- Hi i'm seeing an exception even though i haven't changed anything HOT 2
- How can i set BaseAddress, BaseAddressUsdtFutures for test url's HOT 2
- Mexc wrapper? HOT 3
- Custom KeepAliveInterval to SocketOptions
- CryptoExchange.Net work with Coinbase Pro's API in the Future???
- Improvement: Add "ExchangeName" to "IRestApiClient" HOT 1
- Common interface for SocketClients
- Miss (Parameter 'accountId')) on common PlaceOrderAsync for Huobi
- SetProxy(ClientWebSocket socket, ApiProxy proxy) Uri.TryCreate in part causes unnecessary errors HOT 1
- Question: Does this library or CryptoClients.Net have built-in support for local orderbook management? HOT 2
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 cryptoexchange.net.