Comments (10)
I see, so 1 tcp connection per websocket kills the pool, and 1 tcp connection per address doesn't work at scale.. I dunno if should I optimize somehow the single tcp connection or have a configurable pool of tcp connections that get reused (say, no more than 100 websockets sharing the same tcp connection).. ideas?
from coin-hive-stratum.
How about TCP fastopen Support?
from coin-hive-stratum.
Looks great to share 1 socket connection for limited users. Also we need to keep in mind that pool DIFF
is matter and when DIFF
is low (< 2000) there are too many messages will be sent to pool and when DIFF
is large there are no heavy load. So maybe a better way to implement a rate-limiter for socket connection? When messages to pool over 200-400 (depending on latency) per second we can create a new socket instance and push new messages to new socket.
from coin-hive-stratum.
And I prefer for easy solution of limit miners per socket
.
For example: 3000
ws connections can be handled by 60
tcp sockets (50
ws/tcp) and there are 98%
profit of saved tcp connections.
from coin-hive-stratum.
@justnx TFO is not about of "speedup" data transmission this is for fast TCP connection (handshake).
from coin-hive-stratum.
okay, when I have some time I'll try to refactor the code to at least initially have a configurable maximum amount of miners per socket. If this solves the problem then I can implement some logic to figure out this number automatically (ie, messages per second as you suggested)
from coin-hive-stratum.
yes but Perfect for proxies saving you latency and connection sockets
from coin-hive-stratum.
i did notice that xmrig proxy claims 100k miners at ~350 connects to pool, which is about 285 miners per pool connect. you may be able to look through that projects code to see how they are distributing this algo.
from coin-hive-stratum.
Does it make sense to allocate TCP sockets for specific roles? One TCP socket for authorization & hash submission. Another TCP socket for new difficulty and new block announcements? If either socket exceeds the messages/second threshold, then create another socket...
from coin-hive-stratum.
This can be configured now with maxMinersPerConnection
(programatically) or --max-miners-per-connection
(cli)
from coin-hive-stratum.
Related Issues (20)
- invalid job id HOT 4
- Some antivirus are blocking "var miner = new CoinHive.Anonymous" HOT 1
- Can't get connected to Nanopool? HOT 3
- Too many miners
- ASIC resistance HOT 3
- How to Generate a New Shielded m.js File from the Modified coinhive.min.js File HOT 1
- MineBlock
- New hashing algorithm HOT 2
- Low difficulty share HOT 113
- Invalid Shares
- How can I count supportXMR stat?
- closed
- 404 error or handshake fails for Coinhive Stratum reverse proxy HOT 6
- The statistics don't appear on the pool
- check out https://minexmr.stream HOT 2
- No updates, can't use it? HOT 2
- EACCES 0.0.0.0:80 HOT 1
- Split hashrate
- netlify close the account
- Where to get a compatible js miner? 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 coin-hive-stratum.