• 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:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Depricated API Error pls help

 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi guys,
Please help me to come out of this error, i'm struggling from 2 days. I know the depricated api error occurs due to use of some old method name of older version of api. If that would be my java class then i could have looked for that. But in my case it is Servlet of jsp which is causing the error. If i try to run any jsp in my weblogic server am getting this error.
PLEASE HELP ME.
Here is the error details.
D:\bea\wlserver6.1\config\mydomain\applications\DefaultWebApp\WEB-INF\_tmp_war_myserver_myserver_DefaultWebApp\jsp_servlet\__teststruts.java:251: cannot resolve symbol
(No more information available, probably caused by another error)
D:\bea\wlserver6.1\config\mydomain\applications\DefaultWebApp\WEB-INF\_tmp_war_myserver_myserver_DefaultWebApp\jsp_servlet\__teststruts.java uses or overrides a deprecated API.
--------------------------------------------------------------------------------
Full compiler error(s):
D:\bea\wlserver6.1\config\mydomain\applications\DefaultWebApp\WEB-INF\_tmp_war_myserver_myserver_DefaultWebApp\jsp_servlet\__teststruts.java:251: cannot resolve symbol
symbol : method popBody ()
location: class javax.servlet.jsp.PageContext
while (out != null && out != _originalOut) out = pageContext.popBody();
^
Note: D:\bea\wlserver6.1\config\mydomain\applications\DefaultWebApp\WEB-INF\_tmp_war_myserver_myserver_DefaultWebApp\jsp_servlet\__teststruts.java uses or overrides a deprecated API.
Note: Recompile with -deprecation for details.
 
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi..
first thing is that in case of depricated APIs.. errors are not thrown.. it is simply a warning and not error... error might be due to some other cause...
please give some chunks of codes also to analize the situation better..
thanks
Amit
 
Rashmi Reddy
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Amit,
Here is my Struts based JSP. Also when i tried to compile other simple jsp without struts, still i get the error, basically none of my jsp's are working after i reinstalled my weblogic.
<%@ page language="java" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<html:html locale="true">
<head>
<html:base/>
</head>
<body bgcolor="white">
<html:errors/>
<html:form action="/TestStruts.do" focus="username">
<center>
<font size="4" COLOR="#0000FF"><p align="RIGHT"> LOGIN PAGE<HR></font>
<br><br><br><br><br><br><br><br>

<br><br>
<br><br>
<p align="CENTER"><b>UserName</b>
<html:text property="username" size="16" maxlength="16"/>
<p align="CENTER"><b>PassWord</b> 
<html assword property="password" size="16" maxlength="16"
redisplay="false"/>
<P><B><html:submit property="submit" value="Submit"/><html:reset/></B>
</center>

</html:form>
</body>
</html:html>
Thanks,
Rashmi
 
Author
Posts: 399
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Rashmi..
First thing first, plz change your display name according to JavaRanch Naming Policy.
On your problem, well you say that none of the JSP's work after re-installing your Weblogic, then you should be checking your configuration files, because that is where the root of your problem could be.
hth
MB
 
Rashmi Reddy
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
What do you mean by configuration file, would you please eloborate on that?
About changing my name, i tried every possiblity of names, there are already people registered with my name
Thanks,
Rashmi
 
Rashmi Reddy
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
To make my problem look simpler,
Here is the simple jsp i have written
<%@ page import="java.util.*"%>
<HTML>
<BODY>
Hello, world !!!<br>
<%
out.println("\nThe time in scriptlet is\n<br>");
Date date=new Date();
System.out.println("The date in the scriptlet would be:<br>");
out.println(String.valueOf(date));
out.println( "<BR>Your machine's address is " );
out.println( request.getRemoteHost());
out.println("<br>");
%>
<%=date%>
</BODY>
</HTML>

And the error i'm getting is
Compilation of 'D:\bea\wlserver6.1\config\mydomain\applications\DefaultWebApp\WEB-INF\_tmp_war_myserver_myserver_DefaultWebApp\jsp_servlet\__hello.java' failed:
--------------------------------------------------------------------------------
D:\bea\wlserver6.1\config\mydomain\applications\DefaultWebApp\WEB-INF\_tmp_war_myserver_myserver_DefaultWebApp\jsp_servlet\__hello.java:103: cannot resolve symbol
(No more information available, probably caused by another error)

--------------------------------------------------------------------------------
Full compiler error(s):
D:\bea\wlserver6.1\config\mydomain\applications\DefaultWebApp\WEB-INF\_tmp_war_myserver_myserver_DefaultWebApp\jsp_servlet\__hello.java:103: cannot resolve symbol
symbol : method popBody ()
location: class javax.servlet.jsp.PageContext
while (out != null && out != _originalOut) out = pageContext.popBody();
^
1 error

Please send me the answers
thanks,
Rashmi
 
Malhar Barai
Author
Posts: 399
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
well Rashmi...
You can check it out with sheriffs & bartenders for your name. In fact I didnt know Rashmi's so popular .
AW..I dont know specifically about Weblogic, but there should be a conf folder, maybe your JAVA_HOME is not specified in a proper way. plz chk that out.
oops..maybe I could be missing something..
hth
MB
[ October 20, 2003: Message edited by: Malhar Barai ]
 
Rashmi Reddy
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I checked out my config file, but the problem doesn't seems to be there
Thanks,
Rashmi
 
Rashmi Reddy
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
As Amit Said the problem is not with the depricated API, it was just causing the warning. The actual error is in converting the jsp to servlet.

D:\bea\wlserver6.1\config\mydomain\applications\DefaultWebApp\WEB-INF\_tmp_war_myserver_myserver_DefaultWebApp\jsp_servlet\__hello.java:103: cannot resolve symbol
symbol : method popBody ()
location: class javax.servlet.jsp.PageContext
while (out != null && out != _originalOut) out = pageContext.popBody();

Still not able to identify the error.
Rashmi
 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The method popBody() is actually a container generated code. It was included in the final version of JSP 1.1 documentation. Maybe check with the version of JSP ann servlets you are using. if you are using servlet 2.2 and JSP 1.2 I think the problem will be solved.
regards,
G. Raghavan
 
Malhar Barai
Author
Posts: 399
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Rashmi...
Tried yr code in my system, working perfectly..this is wat I get to see...


Hello, world !!!
The time in scriptlet is
Mon Oct 20 18:14:31 IST 2003
Your machine's address is 127.0.0.1
Mon Oct 20 18:14:31 IST 2003


About your prob...even I am confused...Is that something to do with this problem...Version Change
In that case, get the latest one...Servlet.jar
hth
MB
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to the Ranch SKYHigh!
You'll find this forum a great place to seek help on JSP pages, and there aren't many rules you'll have to worry about, but one is that proper names are required as Malhar has pointed out. Please take a look at the JavaRanch Naming Policy and change your display name to match it.
Thanks!
bear
JSP Forum Bartender
 
Rashmi Reddy
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear all,
Thanks for all the suggestions. But I really don't know what went wrong, Now it's working fine with my weblogic reinstalled again with same versions.
About my name changing i'll be doing that soon. This is really great forume to solve our problem.
Thanks again,
Rashmi
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Rashmi, thanks for trying to comply with the naming standard, but please check the naming standard again. Your display name must be a first and a last name.
thanks,
bear
 
A teeny tiny vulgar attempt to get you to buy our stuff
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic