Comments (7)
I need to find a way to correctly test on distributed servers. I'm seeing issues with spinning up multiple servers on a single machine. I think it's because of it's static and multi-threaded design.
from socket2me.
Tested with 3 servers. Fails over as expected.
NOTE: test servers tend to hang and not release sockets very well.
from socket2me.
hi, ahebet, thanks for your excellent work.
i have a question, i run the socket server, and then run a client connect to the socket server.
then i kill the client process, i found the server's memory is increasing fast.
i doubt there is memory leak when i kill the client, can you give me some clues ?
thank you very much !
from socket2me.
from socket2me.
@songbaoer or you can just send a pull request π
from socket2me.
@ahebert , sorry for late reply,
1γi start a server like following:
` unique_ptr s(new server("vcm_plugin_auth", auth::MD5));
s->set_read_callback(server_receive);
s->listen("0.0.0.0", port);
while(1)
{
this_thread::sleep_for(chrono::seconds(50));
}`
2γand then start a client without addfailover
` unique_ptr c(new client("vcm_plugin_auth", auth::MD5));
static int i = 0;
while(!c->authenticate(ip_addr, port))
{
cout<< "authenticate fail, please check the server ip and port is correct " << endl;
client_s(to_string(++i));
i = i < 10 ? i : 3;
this_thread::sleep_for(chrono::seconds(kHeartBeatInterval));
};
do {
while (c->connected())
{
auto uuid(c->getUUid());
//do something
this_thread::sleep_for(chrono::seconds(kHeartBeatInterval));
}
client_s(to_string(++i));
i = i < 10 ? i : 3;
this_thread::sleep_for(chrono::seconds(kHeartBeatInterval));
cout << "attempting failover" << endl;
} while (c->failover());`
3γwhen i kill the client process , the server memory increasing fast ,
maybe i have wrong way to use your software, could you review my code,
and give me some advices? thanks a lot
from socket2me.
@songbaoer I've opened a new bug to track this. Please refer to #10 for this issue going forward.
I'll investigate this.
Thanks,
Aaron
from socket2me.
Related Issues (7)
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 socket2me.