Comments (6)
Two ways of implementing this that come to mind:
- An extra method in the controller, giving access to stats on demand.
- An extra notification type that is called periodically (once a second, say), providing stats to the user.
from swarm.
Another idea:
- Add a request stats tracker at the level of the request set.
- Stats indexed by request id.
- Allow request handlers to access this, look up the request, and update the stats.
- Allow the user to look up stats for a request by id.
from swarm.
Allow request handlers to access this, look up the request, and update the stats.
This is the only tricky part of the above suggestion. Currently, request handlers have no access to anything at the level of the request set. The request-on-conn would be a possible way to pass a ref to the stats tracker, but that sounds a little bit on the edge of hacky.
from swarm.
Currently, request handlers have no access to anything at the level of the request set.
My top-of-the-head knowledge of the neo client isn't as fresh as it used to be :( The request context forms this conduit between the request set and the individual handlers.
from swarm.
Actually, we already have stats for connection I/O throughput. This might be enough, in practice.
from swarm.
Closing. No current use case.
from swarm.
Related Issues (20)
- Add SwarmServer application base class HOT 2
- Replace internal usage of NodeItem with AddrPort HOT 2
- Make turtle.env.Node less abstract
- Simpler client request interface? HOT 14
- Don't log stats for unused requests
- [turtle] Generate credentials file for the client
- Deprecate non-scoped controller access HOT 3
- Add new throttler / stream processor for use with neo clients HOT 2
- `ISuspendable.resume` implementations must not cause context switching HOT 6
- Differentiate failure reasons of `swarm.client.RequestOnConn.useNode` HOT 1
- Buffer growth warning size limit is now too small
- Neo connection handler slowdown with high number of scheduler worker fibers
- Log warning on attempted access by unauthorised client
- Drop D1 support HOT 1
- Fix neo Suspendable to work with oceans ISuspendable Interface HOT 1
- Stop using templates Const, Immut and Inout HOT 1
- Neo requests escape a reference to a stack variable. HOT 3
- Support alternative task scheduling mechanisms
- Use newest version of ocean to unblock dmd's buildkite 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 swarm.