Particle's Custom RPG
PCRPG Development
»
Development
»
Server-Side Optimization
Username:
1 Hour
1 Day
1 Week
1 Month
Forever
Password:
Home
Help
Search
Quick Search
Advanced Search
[Close]
Login
Register
Pages: [
1
]
2
« previous
next »
Print
Author
Topic: Server-Side Optimization (Read 1870 times)
0 Members and 1 Guest are viewing this topic.
Hack-N-Slash
Elvin Legion
Reputation: +0/-0
Posts: 492
Server-Side Optimization
«
on:
May 27, 2004 12:18 AM PDT »
The server has been doing a great job for the majority of the time, but as of late people slowdowns and crashes are becoming increasingly common. What can be done to resolve this without sacrificing the features we have already? The server connection seems to be enough for what we're doing, but the server seems to be choking on itself.
I'm writing down a list of considerations that I'll put down later today. All the questions will be aimed at possible server code optimizations.
«
Last Edit: December 31, 1969 04:00 PM PST by Hack-N-Slash
»
Logged
[size=200]
I am a fat, wealthy, capitalist pig
[/size]
Hack-N-Slash
Elvin Legion
Reputation: +0/-0
Posts: 492
(No subject)
«
Reply #1 on:
May 27, 2004 01:46 AM PDT »
1. What are the most called functions?
2. What functions take the most resources per call?
3. What has already been done to improve server efficiency?
I'll finish this later
«
Last Edit: December 31, 1969 04:00 PM PST by Hack-N-Slash
»
Logged
[size=200]
I am a fat, wealthy, capitalist pig
[/size]
-eViL-
Minotaur Rager
Reputation: +0/-0
Posts: 880
(No subject)
«
Reply #2 on:
May 27, 2004 05:41 AM PDT »
if you want to solve all the problems of a tribes rpg server, you must kill GetAccessoryList();
but to do that, you must re-write lots and lots o code.
«
Last Edit: December 31, 1969 04:00 PM PST by -eViL-
»
Logged
There's nothing ever wrong but nothing's ever right
Such a cruel contradiction
Hack-N-Slash
Elvin Legion
Reputation: +0/-0
Posts: 492
(No subject)
«
Reply #3 on:
May 28, 2004 12:22 AM PDT »
Anything else? I'm going to browse thru the server code and look for areas for possible optimizations.
Are there any places where sorting is involved? I'd hate to see a freaking inefficient sort (bubble and the like) used all the time.
«
Last Edit: December 31, 1969 04:00 PM PST by Hack-N-Slash
»
Logged
[size=200]
I am a fat, wealthy, capitalist pig
[/size]
-eViL-
Minotaur Rager
Reputation: +0/-0
Posts: 880
(No subject)
«
Reply #4 on:
May 28, 2004 10:41 AM PDT »
hack, i told you the biggest problem in rpg, have a nice time finding anything bigger.
and just for the proof, i'll quote JI :
Quote from: "JI, from weight.cs"
//Replaces the laggy AddPoints(%clientId,
in RefreshWeight (the real lag comes from GetAccessoryList however)
JI put the lag into the mod, and never removed it even though he knew it was there.
«
Last Edit: December 31, 1969 04:00 PM PST by -eViL-
»
Logged
There's nothing ever wrong but nothing's ever right
Such a cruel contradiction
Hack-N-Slash
Elvin Legion
Reputation: +0/-0
Posts: 492
(No subject)
«
Reply #5 on:
May 29, 2004 09:12 AM PDT »
Ok, ok! *runs and hides*
«
Last Edit: December 31, 1969 04:00 PM PST by Hack-N-Slash
»
Logged
[size=200]
I am a fat, wealthy, capitalist pig
[/size]
UnderGod
Centurian Lord
Reputation: +0/-0
Posts: 2,691
(No subject)
«
Reply #6 on:
May 29, 2004 12:07 PM PDT »
Aside for the infinite loops that constantly run, and that function, there is nothing else that can really be fixed short of writing a special app to manage the server.
«
Last Edit: December 31, 1969 04:00 PM PST by UnderGod
»
Logged
"The right man in the wrong place can make all the difference in the world"
Hack-N-Slash
Elvin Legion
Reputation: +0/-0
Posts: 492
(No subject)
«
Reply #7 on:
June 3, 2004 07:27 AM PDT »
Wow, I just looked at getAccessoryList... frightening bit of code. Now I understand why you said that eViL: All those looped checks on player inventory.
I'm inclined to toy with it.
eViL, I also recall in the past hearing you say that fetchdata had an impact on the server as well.
«
Last Edit: December 31, 1969 04:00 PM PST by Hack-N-Slash
»
Logged
[size=200]
I am a fat, wealthy, capitalist pig
[/size]
UnderGod
Centurian Lord
Reputation: +0/-0
Posts: 2,691
(No subject)
«
Reply #8 on:
June 3, 2004 08:33 AM PDT »
In a way it does, but there is nothing you can do about that short of rewriting the entire mod.
«
Last Edit: December 31, 1969 04:00 PM PST by UnderGod
»
Logged
"The right man in the wrong place can make all the difference in the world"
-eViL-
Minotaur Rager
Reputation: +0/-0
Posts: 880
(No subject)
«
Reply #9 on:
June 3, 2004 10:19 AM PDT »
what oz said.
but yes, fetchdata is a giant waste of server clock cycles.... it is called just about as much as the accessory list function is.
«
Last Edit: December 31, 1969 04:00 PM PST by -eViL-
»
Logged
There's nothing ever wrong but nothing's ever right
Such a cruel contradiction
Hack-N-Slash
Elvin Legion
Reputation: +0/-0
Posts: 492
(No subject)
«
Reply #10 on:
July 6, 2004 07:51 PM PDT »
Woot, my internet has finally come back to life! The service outage got me bored enough to probe more into this.
I wouldn't mind splitting fetchdata into separate functions and rewriting the code accordingly in order to kill that huge mess of if statements. The large if block would have to be a factor in the server's problems if fetchData is called so much.
If this doesn't fix the problem, it would definitely would reduce the time calling info from $ClientData
Either that or I call information from $ClientData whereever fetchdata is called.
If I'm going about this wrong, tell me what I would need to do, in exact terms. I have LOTS of time on my hands, and I need the practice anyways.
If I get this fixed, I'll move on to dealing with getAccessoryList.
«
Last Edit: July 7, 2004 04:23 AM PDT by Hack-N-Slash
»
Logged
[size=200]
I am a fat, wealthy, capitalist pig
[/size]
UnderGod
Centurian Lord
Reputation: +0/-0
Posts: 2,691
(No subject)
«
Reply #11 on:
July 6, 2004 11:21 PM PDT »
The best way to rewrite something like the character saving function, is to turn it into 1 quick line of code that still saves everything.
«
Last Edit: December 31, 1969 04:00 PM PST by UnderGod
»
Logged
"The right man in the wrong place can make all the difference in the world"
Xanth
Minotaur Rager
Reputation: +0/-0
Posts: 760
(No subject)
«
Reply #12 on:
July 7, 2004 05:15 AM PDT »
Is is just possible to leave the FetchData calls in and just replace the function with and empty function that does nothing?
«
Last Edit: December 31, 1969 04:00 PM PST by Xanth
»
Logged
Currently playing BF2
(Name: Xanth-911 ) BooYa!!
Hack-N-Slash
Elvin Legion
Reputation: +0/-0
Posts: 492
(No subject)
«
Reply #13 on:
July 7, 2004 07:42 AM PDT »
If you want to break the mod...sure.
The function is used to call character information from the server.
«
Last Edit: December 31, 1969 04:00 PM PST by Hack-N-Slash
»
Logged
[size=200]
I am a fat, wealthy, capitalist pig
[/size]
UnderGod
Centurian Lord
Reputation: +0/-0
Posts: 2,691
(No subject)
«
Reply #14 on:
July 7, 2004 11:19 PM PDT »
Yeah... No fetchData, no RPG.
«
Last Edit: December 31, 1969 04:00 PM PST by UnderGod
»
Logged
"The right man in the wrong place can make all the difference in the world"
Pages: [
1
]
2
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General
-----------------------------
=> Common Topic Symposium
=> Off-The-Wall (OTW)
-----------------------------
Assistance
-----------------------------
=> Documentation
=> Assistance & Feedback
=> The Dog House
-----------------------------
PCRPG Development
-----------------------------
=> Development
Loading...