Architecture Problem

D

Devnet

Hi all,

I've been a Notes developer for years but I am trying to move into the J2EE
world.

Essentially I want to capture data from a web form, format the data into an
XML stream, send the stream to a server, receive the response and display in
the browser.

I've broken it down into parts while I am learning. I've created the form in
a JSP, I click a button and it creates the XML file, I then manually run a
java program which sends the file to a remote server, I receive the response
and then manually display in the browser.

OK, so now I want to automate this and separate the presentation from the
business logic etc, which is where I'm stuck. Should I use a Java Bean, EJB,
a Servlet or some other way to take the form data and create the XML stream
and send to the server? Is a JSP page the best thing to use for this?

Any advice is greatly appreciated.

Regards,

Michael
 
A

Andy Fish

I'm not sure I understand how you want it to work.

presumably you are clicking a button on the browser to build the xml, so how
does it get it into a file?

it's no good having a java program to send the file to the server if you
want it to run on a web client
 
D

Devnet

I create the file from the button click, but what I want to do is from the
button click use a template of the xml request file, read the template in
using DOM then write the data from the fields into the DOM representation
and then send that as a stream to a remote server. My problem is what should
I use to do this, ie. Am I better to use a servlet to parse the template and
write the data in and send the stream to the server or would an EJB be
better or am I going about this the wrong way.

Thanks Michael.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,260
Messages
2,571,039
Members
48,768
Latest member
first4landlord

Latest Threads

Top