Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / Tools / July 2005

Tip: Looking for answers? Try searching our database.

When is a J2EE framework the right solution?

Thread view: 
DRM - 09 Jul 2005 22:01 GMT
We are currently interviewing consulting/architect/development
groups for a new web-based project.  The winner of this project
will architect, design and develop the project. Currently, we have
no expertise in the Java world and we want to make sure that we
get the architecture right the first time (assumng that's possible).
Some of our interviewees recommend going with a J2EE
framework whereas others claim that it's overkill and/or bloated.
Given the following minimum requirements, which group is
correct?

   1) The system must be platform neutral.

   2) The client/presentation tier must be completely decoupled
from the business/middle tier.  (I should be able to talk to the
middle tier via applets, flash, CE, perl, PHP, etc.)

   3) The system must be able to support 100,000 users.  (Aside:
how does that translate into concurrent users? 10%?)

   4) The system will be sold to a variety of organizations, so the
system must be capable of talking to a plethora of legacy systems
with no (or  minimum) custom programming.  For example, we
may need to interface to an existing database for authentication
purposes.

   5) Cost is not a factor.

   6) Speed is a factor.  We want a system tested and running
within 9-12 months.

We foresee the need for distributed transactions down the road.
Would this influence your decision. Would this influence the
architecture of the system or the design pattern that you would use?

What if the system must support 1,000,000 users -- would this
influence your decision?

If other newsgroups are appropriate, please adjust headers.

Thanks!
EricF - 10 Jul 2005 05:58 GMT
>We are currently interviewing consulting/architect/development
>groups for a new web-based project.  The winner of this project
[quoted text clipped - 36 lines]
>
>Thanks!

Distributed transactions? Then J2EE is the way to go (though there are TP
monitors that wupport this.)
Steve Jorgensen - 10 Jul 2005 22:41 GMT
I'm no expert, but it seems like what you need to know is how successful the
potential group has been at implementing similar systms for other clients,
-not- what technology they used to do it.

The group you will hire contains the people qualified to determine what the
platform should be, not you.  If you choose a technology first, you're making
the decision with insufficient exprience to do so, and also artificially
limiting the number of groups you might be able to recruit to do the work.

>We are currently interviewing consulting/architect/development
>groups for a new web-based project.  The winner of this project
[quoted text clipped - 36 lines]
>
>Thanks!
DRM - 11 Jul 2005 07:54 GMT
> I'm no expert, but it seems like what you need to know is how successful
> the
[quoted text clipped - 7 lines]
> the decision with insufficient exprience to do so, and also artificially
> limiting the number of groups you might be able to recruit to do the work.

Well, I certainly don't want to step on any toes, but as the person who will
be responsible for maintaining the system, I think I've got some say in the
technologies used.  Would the following be more appropriate?

   1) The system must be platform-independent.
   2) The client tier must be completely decoupled from the business tier
using
open standards and protocols (XML/Soap over http(s)).
   3) The business tier must be completely decoupled from the model tier
using
open standards (ODBC).
   4) We will gradually assume maintainence of the system.  The vendor is
expected to transfer skills to our team members.
   5) System must be scalable.

Is that saying enough?  Seems to me that, for example, "System must be
scalable"  isn't going far enough.  What are the appropriate questions to
ask?

Thanks.
Steve Jorgensen - 11 Jul 2005 08:34 GMT
>> I'm no expert, but it seems like what you need to know is how successful
>> the
[quoted text clipped - 11 lines]
>be responsible for maintaining the system, I think I've got some say in the
>technologies used.  Would the following be more appropriate?

I didn't mean to indicate that you shouldn't have a say, but since
1. You have a question about what technology is appropriate
2. You don't have the answer yourself
3. You're trying to hire a group to do the work

It seems to me that the group you will hire should be who will answer the
question.

>    1) The system must be platform-independent.
>    2) The client tier must be completely decoupled from the business tier
[quoted text clipped - 10 lines]
>scalable"  isn't going far enough.  What are the appropriate questions to
>ask?

That sounds excellent to me.
Phlip - 11 Jul 2005 15:30 GMT
> Well, I certainly don't want to step on any toes, but as the person who will
> be responsible for maintaining the system, I think I've got some say in the
> technologies used.

In addition to requiring your team to express the list as tests, if you
indeed will maintain this system then you should start that endeavor as
early as possible too. That means each time they deliver, you take delivery,
deploy to a reference system, manually test, and see if you can tweak the
configurations and code.

You will still do QA. It just shouldn't be the "clean up the slops" kind.
Inspect the test coverage, over time, too.

Signature

 Phlip
 http://www.c2.com/cgi/wiki?ZeekLand

paul campbell - 17 Jul 2005 12:22 GMT
> Well, I certainly don't want to step on any toes, but as the person who  
> will
[quoted text clipped - 7 lines]
> using
> open standards and protocols (XML/Soap over http(s)).

Why - what direct business value does this provide ? such a constraint
may well drive the technical architecture in the wrong direction and
compromise scalability and make the system needlessly complex to  
administrate
(for example).

>     3) The business tier must be completely decoupled from the model tier
> using
> open standards (ODBC).

How do you know that you need physically seperate "business" and a "model"  
tiers -
maybe direct method invocations are the best way ?.
And even if you do - have you (as above) considered the profound effects  
such
a constraint may have on the viability of the system going forward.

[ BTW, ODBC is not a protocol for addressing a model - it is a protocol for
addressing a relational database.]

Solve logical problems with logical solutions. Imposing a physical protocol
purely for the purpses of logical decomposition of the system is virtually
guaranteed to be *disaterous*.

Paul C.
DRM - 17 Jul 2005 20:06 GMT
>> Well, I certainly don't want to step on any toes, but as the person who
>> will
[quoted text clipped - 13 lines]
> administrate
> (for example).

The value is that it allows us to more easily integrate applications from
partners by providing an api to our system over standard protocols.  If
I know  that disparate clients will have to communicate with the system,
why would I use anything other than an open standard?

>>     3) The business tier must be completely decoupled from the model tier
>> using
[quoted text clipped - 10 lines]
> for
> addressing a relational database.]

I'm using model tier as a synonym for RDBMS -- yeah, I know they're not
the same thing.  I simply require the ability to talk to any RDBMS.

> Solve logical problems with logical solutions. Imposing a physical
> protocol
> purely for the purpses of logical decomposition of the system is virtually
> guaranteed to be *disaterous*.
>
> Paul C.
Phlip - 10 Jul 2005 23:08 GMT
> We are currently interviewing consulting/architect/development
> groups for a new web-based project.

You are declaring that your highest priority features are...

>     1) The system must be platform neutral.
>     2) The client/presentation tier must be completely decoupled
>     3) The system must be able to support 100,000 users
>     4) talking to a plethora of legacy systems
> What if the system must support 1,000,000 users

Select the team who tells you they will write an automated test for each of
those things during the first week, and will pass those tests - alongside
all the other tests they will write - for the remaining duration of the
project.

Your question is essentially this: "How can I tell the team I pick now will
write something that still has these features a long time from now, after we
start deploying?" The answer is you cannot. Your team could pick J2EE, or
Ruby on Rails, or Apache with mod Perl, or COBOL, and their programs'
performance now will have nothing to do with its performance after they have
loaded it up with all the business features you will request.

Pick a team known to do good work with a low defect rate and a fast
turnaround on feature requests. Such teams typically write automated tests
for everything they do, as they write the tested code. The team should not
treat you as their QA department. They _should_ provide a new version, with
new bug-free features, every few days. Give them small enough feature
requests so they can develop incrementally.

Order that team to implement the most important features first. This is so
you know you have those features, and so their tests will constrain the
development of all future code. Nobody will be able to make a mistake, and
put a bottleneck into the system, if the test that supports 100,000 users
per day (or 500 per second) fails. They will immediately back out that
mistake and try again.

Writing tests in order of business priority is an incredibly powerful way to
constrain development, so all future changes support the most important
goals.

I'm against J2EE myself, but you will find many Java programmers who write a
ratio of test to production code > 3:1.

Signature

 Phlip
 http://www.c2.com/cgi/wiki?ZeekLand

DRM - 11 Jul 2005 08:15 GMT
>> We are currently interviewing consulting/architect/development
>> groups for a new web-based project.
[quoted text clipped - 46 lines]
> a
> ratio of test to production code > 3:1.

Some of our interviewees have assumed that we would do the QA and we
let that go right by without comment.  I've modified my requirements to
reflect
your suggestion.

Thanks for your comments!
David Wallace - 27 Jul 2005 07:30 GMT
According to Phlip <phlip_cpp@yahoo.com>:

> You are declaring that your highest priority features are...
>
[quoted text clipped - 8 lines]
> all the other tests they will write - for the remaining duration of the
> project.

Hmm.  If this were my project, I would select that team to explain just
how they propose to accomplish this particular miracle, and short of
a really convincing detailed explanation, fire their sorry a.ses in favor
of a team that had actually read the requirements and thought about
how to meet them.  The first team has shown evidence that they are
a team of yes-men and yes-women who are more concerned with telling you
what they think you want to hear than actually solving the problem
at hand.  In all probability, they will happily tell you that everything
is hunky-dory while the project smartly marches off the nearest cliff.

That's not to say that their approach wouldn't work with some detailed sets
of requirements - just that it seems hopelessly unrealistic for
this particular set of requirements.  I do acknowledge that I'm not
an expert in this kind of system, but I think even I can tell when
someone is blowing that much smoke at me.  

To take the requirements one by one:

    1) The system must be platform neutral.

This sounds like the kind of issue that requires a design review rather
than an automated test to assure.  Sure, I would expect to see a line
in the overall test plan that specifies acceptance tests to be run on
multiple platforms, but that's not sufficient to assure true platform
neutrality.  You need designers who can identify what technologies
are truly portable across the platforms of interest, and implementers
who know how to distinguish between portable and platform-specific code.

   2) The client/presentation tier must be completely decoupled
   from the business/middle tier.  (I should be able to talk to the
   middle tier via applets, flash, CE, perl, PHP, etc.)

Again, something that is primarily addressed in an architecture
review.  You will probably be able to add tests for individual
communication methods with the middle tier over time, but how
do you plan to test "complete decoupling" of the tiers via an
automated test in week 1?  Send the chief architect an email
asking him/her if there are any hidden dependencies?

   3) The system must be able to support 100,000 users.  (Aside:
   how does that translate into concurrent users? 10%?)

Sounds to me like you will need some sort of load simulator
and enough of the system working that you can generate a sample
workload before you can start to test this.  How do you plan
to automate this in week 1?  Call the stub for "create user"
100,000 times and follow with a couple of transactions?
"Yeah, this test verifies that we can support 100,000 users
as long as only one of them is using the system at a time."

   4) The system will be sold to a variety of organizations, so the
   system must be capable of talking to a plethora of legacy systems
   with no (or  minimum) custom programming.  For example, we
   may need to interface to an existing database for authentication
   purposes.

This sounds like an open-ended requirement that will evolve over
the lifetime of the product into many specific examples.
At project start, the best you can hope for is to have a few examples
of such legacy system requirements and think about what common features
might help support them.  I really want to know how the proposed
automated test is going to measure the amount of custom programming
required to support a given system.

Signature

Dave Wallace        (Remove NOSPAM from my address to email me)
It is quite humbling to realize that the storage occupied by the longest
line from a typical Usenet posting is sufficient to provide a state space
so vast that all the computation power in the world can not conquer it.

pven - 11 Jul 2005 07:00 GMT
The biggest adavantage you stand as a firm with J2EE is the number of
people available in the market who have the skill in using the
platform.

However, the biggest factor you need to consider is the selection of an
architect who had  or designs the system considering your requirements
of the user-base size.

With a possible user base of 1,000,000, the infrastructure components
like load balancers, clustering etc would need to come in to play to
help you provide through put. Here, the architect has to consider this
and plan the design on J2EE accordingly.

An example: the biggest bottle neck for any system is the retreival of
data from the data store. For your system, lets say if I have an RDBMS
with 100 tables, the architect should layer all the database
transactions ( beans that retreive data, update data ) as a separate
service and this service should be hosted on the database server. The
database server should be a cluster running the RDBMS alone.  All other
business processes should be running on a separate servers...

Also, there is no support for multiphase transactions that cross system
boundaries in J2EE. You will have to design and build the system for
this which can be pretty complex....
frebe - 11 Jul 2005 11:42 GMT
To use J2EE or not does not have to be a big question. First J2EE is
many things. You talk about web solutions, so under any circumstances
you will use some parts of J2EE, although you don't use a J2EE
application server.

The big questing is if entity beans should be used or not. I strongly
advice you not to use entity beans. The model is flawn and after 5
years, Sun has realized this and is rewriting the entire concept.

Next question is in what extent they are going to use session beans. My
advice is to only use one or a few session beans as facade objects. All
other classes should be plain old java objects (POJO). In EJB3.0 all
objects can be POJOs, you don't have to implement specific interfaces.

If you ask your developers to minimize the coupling to EJB, it will be
easier to convert your application to live outside a J2EE container
(server).

The number one benefit with a J2EE application server is support for
distributed transactions. Doing this without an J2EE application server
is possible if you have developers that knows that they are doing (and
if you use an application server you also need developers that knows
what they are doing). But at present time I would recommend a J2EE if
you really need this feature. If you don't need distributed
transactions (there are many ways to live without them), I would
strongly recommend not using an J2EE application server. There are many
light-weight componentes providing features like connection pooling and
caching.

Fredrik Bertilsson
http://butler.sourceforge.net
pven - 12 Jul 2005 06:22 GMT
> The big questing is if entity beans should be used or not. I strongly
> advice you not to use entity beans. The model is flawn and after 5
> years, Sun has realized this and is rewriting the entire concept.

Hi,

I have read some debates on EB and most of them
are against its usage.

But when I look at it the concept of wrapping a record
as an object and the container owning the responsibility to
persist the content to the content sounds very neatfor me.
(Separation of concerns..... )

Can you share on why the concept is flawed ?
Is it the implementation of EB by vendors which
is flawed .. or is it the J2EE specifications that
do not allow vendors to provide a good implementation.

This query is something out of context from the
original post, my apologies.
Wojtek Bok - 12 Jul 2005 18:31 GMT
>>The big questing is if entity beans should be used or not. I strongly
>>advice you not to use entity beans. The model is flawn and after 5
[quoted text clipped - 9 lines]
> persist the content to the content sounds very neatfor me.
> (Separation of concerns..... )

I don't like them because very rarily do you work with just a single
table/row. So now you need to encapsulate several tables (and columns)
in a single object. And different "use cases" use different mixes of
tables/rows/columns.

I separate each use case into its own package, then each class therein
acts in concert to satisfy that one use case. Yes, there is redundancy
in SQL code (and some classes), but I have clean separation. Only the
framework is common.
frebe - 13 Jul 2005 08:27 GMT
> But when I look at it the concept of wrapping a record
> as an object and the container owning the responsibility to
> persist the content to the content sounds very neatfor me.
> (Separation of concerns..... )
> Can you share on why the concept is flawed ?

Mapping a record to an object is a good solution, but when you select
records from the database, entity beans only allow to to select from
one table. Related records have to be fetched in other database calls.
This can give you very bad performance in a relational database. The
concept would work fine in a network database, but network databases is
not used anymore because the poor querying capabilities and the
problems with data integrity.

Fredrik Bertilsson
http://butler.sourceforge.net
steph - 13 Jul 2005 20:14 GMT
>> But when I look at it the concept of wrapping a record as an object and
>> the container owning the responsibility to persist the content to the
[quoted text clipped - 5 lines]
> table. Related records have to be fetched in other database calls. This
> can give you very bad performance in a relational database.

Are there better alternative (particularly Java based) ???

Thanks
frebe - 14 Jul 2005 08:54 GMT
Yes,
OR mappers such as Hibernate or my own http://butler.sourceforge.net.

Fredrik Bertilsson
http://butler.sourceforge.net
paul campbell - 17 Jul 2005 12:44 GMT
>> The big questing is if entity beans should be used or not. I strongly
>> advice you not to use entity beans. The model is flawn and after 5
[quoted text clipped - 14 lines]
> is flawed .. or is it the J2EE specifications that
> do not allow vendors to provide a good implementation.

The EB spec attempts to address too many problems at once -
authorisation, distribution, transactionality and persistence.

However in every system Ive ever seen (or heard of) only
persistence is directly relevent at the entity layer, with
all the others being delt with at the session level.

As a result of this the persistence facet of EB is extremely
clumsy limited and intrusive especially compared with state of
the art O/R mappers like hibernate and toplink.
(I used toplink about 3 years ago and even then it was probaly
3 years ahead of where EJB is *now*).

Paul C.


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.