HttpSession gets generated again and again!! PLEASE HELP ME!!!!

C

che

Hi!

I'm working with JBoss (4.0.3) and EJB 3.0.

I have developed a petsore web application, with ejb 3.0 and jsp.
I have some entities and session beans (one stateful for a cart and
theothers are stateless), one servlet and and 5 jsp pages.

Every JSP page calls the controller servlet which holds the ejbs and
puts them into session or request scopes and then calls the jsp pages
to show the objects. I guess it is called "facede" pattern o.s.l.t.!

I'm working with two computers, which are connected, one is a pc and
the other is a notebook.

JBoss is installed on the pc an I invoke the application on my
notebook.

If I invoke the app remotely like described above (with this call:
http://192.168.2.2:8080/petshop)

everything is working fine, but if I try to work on the pc, where
jboss is installed, and the app is deployed (with his call:

http://localhost:8080/petshop
OR
http://127.0.0.1:8080/petshop)

the httpSession is getting generated again and again; everytime when
the controller Servlet is invoked!

Can someone tell me - please - what I'm doing wrong?

Why does it work remotely, but not locally?
 
J

Jon Martin Solaas

che said:
Can someone tell me - please - what I'm doing wrong?

Why does it work remotely, but not locally?

Should work the same both locally and remote, try to use the
192.168-adress in both cases and see what happens. Maybe it's a
jboss-feature, try look it up in the jboss-forum.
 
C

che

Hi Jon Martin,

thank you for your reply.

I have already done that. It dosen't work, neither with the
http://localhost:8080 nor with the IP http://127.0.0.1:8080, just when
I work locally with the network IP address, it works locally. But
normaly, it should also be possible to use the localhost or
127.0.0.1:8080, without any drastic changes!!

I have also made a thread in jboss forum:
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3900118#3900118
But there is no reply yet!

Anyway, I will post the soloution here, if I should find one!
 

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

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top