Java EE App design question
Hi all,
I've have to design an Java EE application which consists of a "Web Client Tier" which handles web based users and "App Client Tier" which consists of several application clients.
Points to concern:
1. The load from app clients will be more than from web clients.
2. Typically the web client numbers may be around 1000 - 2000 and app clients may be around 10000 - 20000.
3. The app clients will just send messages continuosly which needs to be stored in the database.
4. The web clients tier and app client tier can function independently.
5. The database will typically reside in a separate machine.
I'm thinking of the following design options:
Option 1:
Keep the business logic layer as the single point interface to Data Access for both Web Client and App Client tiers.
Option 2:
Keep a common service interface for Data Access Layer which can serve both web and app clients.
Option 3:
Keep a data access layer in both Web client tier and data access tier.
Which option should i choose ?
It would be great if you can suggest any other options.
Kindly provide your valuable suggestions.
Thanks in advance,
James
> Hi all,
> I've have to design an Java EE application which
> consists of a "Web Client Tier" which handles web
> based users and "App Client Tier" which consists of
> several application clients.
>
> Points to concern:
> 1. The load from app clients will be more than from web clients.
The app is not interactive?
> 2. Typically the web client numbers may be around
> 1000 - 2000 and app clients may be around 10000 -
> 20000.
Better think about clustering.
> 3. The app clients will just send messages
> continuosly which needs to be stored in the
> database.
This is a batch job, then?
> 4. The web clients tier and app client tier can
> function independently.
What else would they do?
> 5. The database will typically reside in a separate
> machine.
Of course. It'd be foolish to run the database and the app server on the same machine.
>
> I'm thinking of the following design options:
>
> Option 1:
> Keep the business logic layer as the single point
> interface to Data Access for both Web Client and App
> Client tiers.
How is this different from 2?
> Option 2:
> Keep a common service interface for Data Access Layer
> which can serve both web and app clients.
I prefer this one.
> Option 3:
> Keep a data access layer in both Web client tier and
> data access tier.
I don't understand this. There's a data access layer that both will use, but not directly. The service will be their gateway. It's the service implementation that will use the data access layer as needed.
> Which option should i choose ?
Go with # 2.
View->Controller->Service-+->Model
+->Persistence.
The web tier is the View->Controller piece. The app can call into the Service as well, so both can use it.
%