Writing servers in java

K

Kruno

Hi,

couple days ago I posted a question on this subject, but think I wasn't
specific enough.
So, once again:
I'm trying to develop an application in Java that will act like a server
(something like Tomcat, but not J2EE server in specific; or James, but not
mail server in specific).
I've studied some code of open source servers in Java, but still some basic
knowledge about server application (not J2EE) are unknown to me.

I would be very thankfull if someone could point me to some resources
(books, articles, documentation, ..) on this subject.

Kruno
 
N

nialltimpson

hey,

what are thisnking of, web server, app server ..... if you narrow it down
maybe I can be of assistance as I've wrote both.

Niall
 
N

nialltimpson

hey,

what are thinking of, web server, app server ..... if you narrow it down
maybe I can be of assistance as I've wrote both.

Niall
 
H

HK

Kruno said:
couple days ago I posted a question on this subject, but think I wasn't
specific enough.
So, once again:
I'm trying to develop an application in Java that will act like a server
(something like Tomcat, but not J2EE server in specific; or James,
but not

Well, I guess you are still not specific enough to get
what you want. A "server" can be as trivial as an echo
server which just sends back whatever you sent to it, or
it can be a complex beast as Tomcat and the like.

For a most trivial tcp server which reads input,
processes it and writes some output back to the client,
have a look at
http://www.ebi.ac.uk/Rebholz-srv/whatizit/monq-doc/monq/net/TcpServer.html
..
The software can be downloaded from
http://www.ebi.ac.uk/Rebholz-srv/whatizit/software .

Harald.
P.S.: Yes, this is a shameless plug.
 
K

Kruno

HK said:
but not

Well, I guess you are still not specific enough to get
what you want. A "server" can be as trivial as an echo
server which just sends back whatever you sent to it, or
it can be a complex beast as Tomcat and the like.

For a most trivial tcp server which reads input,
processes it and writes some output back to the client,
have a look at
http://www.ebi.ac.uk/Rebholz-srv/whatizit/monq-doc/monq/net/TcpServer.html
.
The software can be downloaded from
http://www.ebi.ac.uk/Rebholz-srv/whatizit/software .

Harald.
P.S.: Yes, this is a shameless plug.

Thank you for your answer.
Under "basic knowledge" about server applications I meant: startup
procedures, thread handling in server environment, an all other stuff that
differs
real-world server application from trivial example.

Kruno
 
D

David Van de Voorde

The only thing that one would want to do is to create a "thread pool". This
means, a number of threads is created beforehand, so that when a request
comes in, it can be processed immediately.
For the rest, I don't see anything special about server apps vs. client
apps. Unless, you want to integrate within some environment (connecting to
services as messaging, security, ...)

David.
 
M

Marcin Grunwald

David said:
The only thing that one would want to do is to create a "thread pool".
This means, a number of threads is created beforehand, so that when a
request comes in, it can be processed immediately.
For the rest, I don't see anything special about server apps vs. client
apps. Unless, you want to integrate within some environment (connecting to
services as messaging, security, ...)

David.

It's a little more complicated than you think.


Kruno check SEDA (staged event-driven architecture).
http://www.eecs.harvard.edu/~mdw/proj/seda/
http://www.eecs.harvard.edu/~mdw/talks/seda-sosp01-talk.pdf
http://www.eecs.harvard.edu/~mdw/papers/seda-sosp01.pdf

It's really nice architecture and you can use Sandstorm (SEDA based
platform) - it's simpler to use than to write from the begining.
 

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
473,756
Messages
2,569,540
Members
45,025
Latest member
KetoRushACVFitness

Latest Threads

Top