Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

context JNDI issue

 
Rashid Darvesh
Ranch Hand
Posts: 189
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
i have a webapplication packaged as MMI.war and in the context.xml i defined the context as MMI and have all the necessay parameters for JNDI lookup for mysql connection. i have one website by name www.somename.com which is mapped to public_html directory which is default in my server.xml and when i deploy MMI it goes under public_html/MMI
so when i tryp www.somename.com/MMI tomcat can find my JNDI configuration since it matches the context name and everything works.
Now the issue rises here. i registered onemore website www.somename2.com and mapped it to public_html/MMI. now when i type www.somewebsite2.com since the context is not MMI the JNDI look up doesnt work. Hope i made my point clear any help its a bit urgent. Should i change my context in context.xml file from MMS to www.somewesite2.com any help...
[ February 08, 2007: Message edited by: Bear Bibeault ]
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64631
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please read this with regards to using the term "urgent" in your posts.

I have removed it from the topic title for you.
 
Rashid Darvesh
Ranch Hand
Posts: 189
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i think may be my question was not clesr.
let me put it this way.
i you have some datasource defintion in your context file like forexample

you are binding your databsource to a specific context so if a user types down something like http://somedomain1.com/MMI then i am able to find the context and hibernate is able to retrieve my datasource. till now i was using this pattern. but now the issue is i have mapped www.somedoman2.com to my MMI folder under my tomcat root. now there is no context like MMI.
i only type www.mydonmain2.com and hibernate is not able to find the context rightly since there is no MMI. i just need to know what should i give the context name in my context.xml file under META-INF.
Any help
 
Rashid Darvesh
Ranch Hand
Posts: 189
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Any body has any idea please...
Rashid
 
Rashid Darvesh
Ranch Hand
Posts: 189
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am still waiting for some reply.
Still stuck up with this.
Rashid
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic