Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Using mysql events instead of cronjobs
#1
I looked into dslan_start.bat also in the linux version, basic all it does it's an infinite loop wich is using allot of ressources.

This could be optimized allot with the new events from mysql 5.1.x
Instead of having a system like this
Code:
cronjob(loop) -> php -> mysql command

We could have this
Code:
events(loop inside mysql) -> mysql command

The process is very optimized because it does both processes inside mysql, doesn't have to use php or cronjob.
I hope you think about this optimization, the game ressources could be optimized allot with this thing.
#2
Hi,

I just took a look at these new events ( I only had the old ones in mind ), this seems to be a quite good solution.
You could also create a new Event (dynamically) as a Cronjob in MySQL - that has the advantage that there's not always a worker running who needs resources and if many events reach their execution at the same time MySQl will simply create a couple of instances of the Eventhandler - a single worker-thread will probably lagg because it can only perform the events one by one and not parallel.

MySQl-Events are a good approach to improve the Performance of DSLan anyway ^^



MfG
dispy
#3
yes, i'm using mysql events in some of my web apps
#4
The idea is pretty good, but I don't think we want to translate all the Events into mySQL - It's accutaly good that the DSLan uses lots of resources because it makes it harder to run with more than 10 users...
#5
Könnte man den Thread mal auf Deutsch übersetzen?
#6
kannst du kein englisch? das meiste kann man sich doch aus dem zusammenhang erkennen. wenn du manches nicht weißt, dann übersetz es doch damit http://translate.google.de/translate_t?h...l=en&tl=de#

#7
Sagmal, müsst ihr aus jedem Thread nen Spamthread machen?
#8
hmm another use for this is that ds_lan_start.bat could disapear if you can replace with mysql events. Anyway, it's a long term process
#9
(07.08.2009, 12:54)hip_hop_x Wrote: hmm another use for this is that ds_lan_start.bat could disapear if you can replace with mysql events. Anyway, it's a long term process

As I already mentioned - we are not going to do this. Not in V1, nor in V2.




Users browsing this thread: 2 Guest(s)