PDA

View Full Version : newbie - Is AJAX suitable for this JAVA game?


manuel boucheri
12-09-2009, 02:47 AM
Hello everybody,

I need to develop a business game of the type "browser based" form filling appication with some statistical graphics and tables, and it must be in JAVA.

Being new to AJAX, I´m informed that ZK is the best platform today.

In this stage, the things that bother me (although but I´ve not started yet to study ZK.) are:

1) The server must be heavily Database Driven.

2) I need to store all the form fillings submited by the players.

3) The options of the players must be processed by the simulator engine wich will be on the server.

4) It must be possible to initiate a one-to-one text based private communication between any two players.

5) I´ve to catch and store all those communications.

Is all of this possible?

Or should Î consider Java Applets?


Thanks in advance,
manuel boucherie

Old Pedant
12-09-2009, 06:51 PM
If it must be *all* in Java, then why is a browser to be involved at all?

Why not write it TRULY all in Java, with both the server and the client(s) as Java applications?

But if you mean that only the server needs to be written in Java, then sure, you could do something this simple using, say, JSP pages with *possible* support for AJAX. Before you convince yourself that you NEED to use AJAX, though, study the problem some more.

My gut feel is that the only reason to use AJAX would be for the chat. And then, yes, a Java Applet would likely be a better answer, *IF* you are allowed to specify that the users must have Java installed and available in their browsers.

Understand, if you are limited to HTTP (which AJAX is), then you can't use a "push" model from the server (where the server sends data to the clients whenever it wants to). Instead, you have to use a "pull" model where the browser does *all* initiation of communications.