Sanjay wrote:
>
> Hi all,
> I'm designing a Servlet based data-access utility. The architecture of the
>setup is diagrammatically shown in the attached file. There are about 10 different
>sites at which data is stored, in MS-access mdb files.
> The Servlet will validate the users against these databases. Further
>transactions will also use the same database. Each site is connected to the Web
>server using dial-up connection. There are two m/c at each site, a RAS m/c and a
>winNT m/c on which the mdb file exists.
> The Servlet takes queries from users and creates an instance of a TCP/IP
>client (for each user). This sends the request data to the corresponding TCP/IP
>server over socket. The server (multithreaded) then passes on this request to the
>Database access module, which accesses/updates data from the mdb file thru JDBC-ODBC
>bridge. The client socket accepts data/error msg from the server socket and returns
>it to the Servlet. Servlet then sends the result to the user's browser. A normal
>transaction for a user involved 4-5 of such cycles. (i.e.: session tracking has to be
>done) . The platform is WinNT for all the machines.
>
> I would like to know the following things :
> 1) Is the architecture correct ?
This mailing list rejects attachments, so nobody got to see your diagram. However,
I'd be more than a little concerned about performance and reliability, given this
amount of complexity.
You might also consider using RMI to connect from the servlets to the server
applications -- it can be easier to program to versus a low-level socket connection.
>
> 2) Will there be performance degradation ? (Traffic = max 10,000 users on the
>Servlet and a max 1000 on each Site)
How many of those 1000 users will be simultaneous? That is the key issue for a
servlet based application. Further, how fast will any given user be submitting
queries? These parameters determine how many connections you need to each server. If
it turns out that you need more than a few, I would be *very* concerned about using
Access as the underlying database, and about using the JDBC-ODBC bridge as your data
access mechanism.
>
> 3) How do I implement connection pooling at each site ? (Particularly, how do
>i maintain the number of connections, to be just enough for the request traffic?).
>Can someone gimme code snippet for this please?
Pretty much any servlet text will have sample code. There are also some source code
archive sites described in the FAQs (see the mail message that comes out every Monday
for links) that have connection pool code.
It sounds like you might also need to employ a "connection pooling" type approach on
your socket connections between the servlet and the server applications, or come up
with a mechanism to share them. This is a place where RMI can be quite nice.
>
> 4) Is there a limit to the number of connections that the Access database file
>can handle at one time ?
You bet ... every database has an upper limit. However, Microsoft is the only one
that can really answer that question. I suspect you will find that the realistic
limit (taking performance into account) is pretty low.
>
> 5) Is it feasible to drop the client/server modules and directly access the
>mdb files from the Servlet ? (thru ODBC configured on the Web server) If it is, how
>secure and crash-proof is the ODBC connection over dial-up ?
It's technically feasible (assuming that the ODBC driver deals with modem hang-ups
gracefully, which I could not tell you). A big issue is going to be the impact on
performance. If you have to read lots of data to produce a fairly small HTML page as
a result, you're probably better off with the intermediate servers approach (because
all the database access will be done on that server, rather than over the modem link).
An entirely different strategy, as was pointed out by a different responder, is to
consolidate the information into a single database, running on the same server (or at
least the same local area network) as your web server. You are likely to experience
substantially better overall system performance and reliability with this technique,
assuming that it is practical.
>
> 6) I plan to use Applet-servlet communication. Can anyone please gimme a few
>pointers on this ? and maybe some code snippet to start on.....
Same comment as about connection pools -- most servlet books and some of the FAQ
resources will discuss this issue.
>
> 7) I tried to configure Netscape Enterprise Server v3.6 SP2 (on WinNT SP5) but
>it fails to start the Web Server and Admin Server services. It gives Windows Internal
>Error when i try to manually start the service. Can anybody help me out here ?
Cannot help you here .. I don't use NES 3.6 or WinNT.
>
> 8) Since Session tracking API are not supported by this web server, how do I
>perform session tracking ? Can I use the applet for sending state info to the server
>? How to implement it ?
>
Why isn't session tracking supported? Doesn't it support at least the 2.0 version of
the servlet API? (I know earlier versions of NES used the 1.0 servlet API, but you
could still use plug-in servlet engines like JRun).
Having applets participate in sessions is kind of intricate ... the references on
applet-servlet communication should cover this.
>
> The list is long and many questions are off-topic. But being inexperianced i felt i
>should ask my doubts to all the Gurus out there........PLEASE help me out
>guys........i would be thankful for ANY help on ANY part of the above.....
>
I don't think any of these issues are necessarily off topic. I do think that you
would be well served by hiring a consultant that is familiar with the problems you are
trying to solve, Java technology, and in particular the servlet approach to web based
applications, to review your design. There is a lot of complexity in what you've
described so far, and it is entirely likely that some issue you haven't even mentioned
yet will significantly affect the choice of approach. A mailing list discussion can
deal pretty effectively with individual point questions; it is not as effective at
defining an application architecture for
a complex environment.
>
> Lots of thanks in advance,
> Sanjay Karanjkar
> Systems Engineer
> Tata Infotech Ltd.
>
Craig McClanahan
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html