thanks mike.
Michael Becke <[EMAIL PROTECTED]> wrote:Hi Karthi,
> So does the following code snippet perform what Mike have mentioned...
> HttpClient client=new HttpClient(); // Which will create a
> SimpleHttpConnectionManager
> // by default. So we
> need not create an explicit
>
> //Httpcon
Hi Karthi,
So does the following code snippet perform what Mike have mentioned...
HttpClient client=new HttpClient(); // Which will create a
SimpleHttpConnectionManager
// by default. So we
need not create an explicit
Mike stated
<< I would suggest creating a simple HttpConnectionManager (very similar to
SimpleHttpConnectionManager) that you can force close the connection with. >>
So does the following code snippet perform what Mike have mentioned...
HttpClient client=new HttpClient(); // Which will create a
Thanks everyone.
The EJB restrictions specified at
http://java.sun.com/blueprints/qanda/ejb_tier/restrictions.html state that
Enterprise beans should not listen on, accept connections on, or mutlicast from a
network socket.
Why can an enterprise bean not listen to or accept connection
Hi Karthi,
From the wording it sounds like you are not supposed to run a server
from an EJB. HttpClient creates sockets but it does not listen to or
accept connections, it's a client only. As someone already mentioned it
would be pretty useless if you couldn't make network connections from an
Michael Becke wrote:
Both of
these will create threads.
As I read the spec (but I am completely unfamiliar with EJB and I may be
dead wrong), you can do what you like during a method call. But before
returning form a method call you must ensure that there are no threads
and sockets left behin
Thanks Mike. Now I understand that we can use HttpClient from within EJB as long as
we close the connection. Also Httpclient does not create a Server socket.
Michael Becke <[EMAIL PROTECTED]> wrote:
Hi Karthi,
>From the wording it sounds like you are not supposed to run a server
from an EJB
EJB + threads + httpclient... yes does break the letter of the spec's,
but yep it works and it works just fine.
Who ever wrote the spec that said you couldn't open a socket in an EJB
really wasn't living in the real world.
The only thing to watch is that MultiThreadedConnectionManager does
sta
mmons HttpClient Project"
To
[EMAIL PROTECTED]
cc
Subject
Invoke a httpclient in a EJB
Hi,
We have all requests posted to a servlet which delegates the
request to a Stateless Session Bean. Does creatring and invoking a
Httpclient postmethod in a helper class invoked by the St
hmmm, EJB + remote DB via jdbc needs sockets?
You can use EJB with socket, as long as the operation is quick.
In some case http socket operation can hang due to long response delay.
-D
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
Hi Karthi,
Unfortunately I don't have much experience with EJBs, but if the spec
says that you can't open sockets, then it will be pretty hard to use
HttpClient. Perhaps someone else on this list has some more experience
in this matter.
Any EJB + HttpClient users out there?
Mike
On Aug 4, 2004
Hi,
We have all requests posted to a servlet which delegates the request to a
Stateless Session Bean. Does creatring and invoking a Httpclient postmethod in a
helper class invoked by the Stateless Session Bean violate any of the EJB
specifications. (EJB spec says sockets are not to be cr
12 matches
Mail list logo