• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
Sheriffs:
  • Rob Spoor
  • Junilu Lacar
  • paul wheaton
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
  • Scott Selikoff
Bartenders:
  • Piet Souris
  • Jj Roberts
  • fred rosenberger

Error when connection to servlet from java class

 
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello ranchers,


I m facing a very different and unique issue.

I have a java file which calls servlet.
and my java file is loaded in oracle using loadJava command.
Then those class files were published and a package was created.

suppose if my class contains 3 methods,
then my package will contain 3 functions.


now when i execute this function ..............i get the return value as FALSE..
which mean it is not able to establish connection with servlet.

I have also maintained logs of class file hitting the servlet.
when i execute the fucntion directly from java file my logs are registered,
but when i do the same from database.no logs is registeted.

Any help will be appreciated.

its urgent.

Also attching herewith the log files.
 
Ranch Hand
Posts: 453
Google Web Toolkit Hibernate Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Ankita Jha wrote:Hello ranchers,
I have a java file which calls servlet.



strange
why are you calling a servlet from a java file ???

avi sinha
 
Ranch Hand
Posts: 494
Eclipse IDE Postgres Database Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ankita Jha..

Do you mean call Servlet(exposed as WebService)?..
 
Bartender
Posts: 2270
20
Android Java ME Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Whats the problem calling a servlet from a java application, even if its not exposed as a web service. Look into URLConnection or HttpURLConnection classes under java.net package. Ankita is facing a different issue i.e. hitting the servlet from oracle.
 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That would be an strange idea, which I've never considered before, but I think it worth your effort to get it through.
Connect to a Servlet, I just wonder what you are doing by then. Do you mean that you would like to request some message from it just like an browser do, or something like web service?

Hoping for further discussion.
 
reply
    Bookmark Topic Watch Topic
  • New Topic