keeping track of clients connected to server
i have a server class that implements the runnable method, and i want to keep track of the clients connected to it so i can disconnect all of them via server class method.
I've seen that a common practise is to use clientHandlers that are Runnable so that each client can run concurrently with the others, but i still dont get how to store the connected client object to the server (if its even possible)
3 Replies
⌛
This post has been reserved for your question.
Hey @asdru! Please useTIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here./close
or theClose Post
button above when your problem is solved. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.
keep a list of all clients that is shared between whatever handles clients
💤
Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived.
If your question was not answered yet, feel free to re-open this post or create a new one.
In case your post is not getting any attention, you can try to use /help ping
.
Warning: abusing this will result in moderative actions taken against you.