Performance of SysActions/Events vs Extensions

Post here your questions about Actionscript and Java server side extensions development.

Moderators: Lapo, Bax

mugambs
Posts: 32
Joined: 11 Dec 2008, 12:05
Location: United Kingdom

Performance of SysActions/Events vs Extensions

Postby mugambs » 13 Feb 2010, 14:49

If i wanted to override the default SysActions and SysEvents like joinRoom(), createRoom(), onUserEnterRoom etc. with my own implementations using an extension, what sort of performance difference could i expect to get?

Of course it depends on the quality and optimisation of the extension code to an extent, but lets assume thats ok.

I would handle all the custom actions / events using JSON rather than XML, thus saving a bit of bandwidth.

Looking at the diagram, it seems the System Handler and the Extension Handler work in a very similar way. Is there any reason to think one or the other would perform better.

My goal is to create a clustered architecture, with cross-server visibility of SysActions, hence the need (i think) to override them.
User avatar
Lapo
Site Admin
Posts: 23008
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 13 Feb 2010, 16:08

Hi,
I don't think there should be significant differences.
But it's not clear what you are thinking to do:
If i wanted to override the default SysActions and SysEvents like joinRoom(), createRoom(),

You can handle Joins and CreateRoom in your extension, sure, adding validation and/or extra logic, but overriding the inner working ... that's not possible.
Lapo
--
gotoAndPlay()
...addicted to flash games
mugambs
Posts: 32
Joined: 11 Dec 2008, 12:05
Location: United Kingdom

Postby mugambs » 13 Feb 2010, 16:44

Well, the reasoning behind it was for clustering purposes. I want to have a collection of fairly large rooms supporting about 500-600 connected users at any time, and enable players connected across a cluster of servers to interact almost seamlessly.

The idea is to set the limbo property to true and handle actions (joinRoom etc) and events (onUserEnterRoom) through a custom extension. The custom handlers would filter the list of recipients that the event notification goes to i.e. not sending it to blocked players / non-friends for example.

In addition, i would want to fire the event to other servers in the cluster. As far as I can tell, its not possible to arbitrarily fire built-in onUserEnterRoom events to players, so i would have to fire my own custom onUserEnterRoom event (done via the onExtensionResponse mechanism).

So im not really talking about overriding in the true Java sense of the word, but creating a set of replacement API's that perform the same function as the built-in actions / events, but additionally do my filtering and cross-server notifications.

Perhaps i'm totally off track here...:-)

Return to “Server Side Extension Development”

Who is online

Users browsing this forum: No registered users and 21 guests