Win a copy of Spring Boot in Practice this week in the Spring forum!

babu thannasi

Greenhorn
+ Follow
since Feb 26, 2006
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
1
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by babu thannasi

thanks Pawel & Roel , it makes sense to me .
Hi , Following, code is taken from K&B 7 chapter 1 Self test Question 6.


the answers is Compilation Succeeds.

Here, what i am trying to understand is ,
1. why line 7 is not failing, i mean compile time . the reason i am thinking this should fail is, because the class Phone3 is not declared abstract.
2.why line 5 is not failing , again compile time, i thought while over ridding even method signature and return type has to be identical to super class method, in this case, the subclass is allowing a parameter x.

i think its an errata in K&B7 , the answers should be at least E ( line 7 fails to compile). please correct me if i am wrong.

Roel De Nijs wrote:

babu thannasi wrote:So the Question is , what is happening here with and with out final( on line 6 & 7) , could any one please help me understand why it is so ?


This thread provides very good explanations (including a bunch of code examples) about the same topic. So definitely have a read, will be very informative!



thanks Roel , execellent thread!!

Henry Wong wrote:

Paweł Baczyński wrote:Oh, sorry! My mistake. This quote comes from JVMS, not JLS.



Interestingly, while the specs are different, it is very similar, and even matched to step 6 and step 9. It is only the wording that is different. I will speculate that the two sections was cut and pasted from each other.

Henry



thanks Henry, thats what i thought after reading both the pages.
Hello all , i am preparing for OCAJP 7 , i was reading thru one of the posts related to Static in this forum, and used the code from that , while executing below code.



code prints --> inside Static : int 1 10 int2 0 and inside main: int 1 10 int2 2.

how ever when i removed the final , i see a inside Static : int 1 0 int2 0 and inside main: int 1 10 int2 2.

So the Question is , what is happening here with and with out final( on line 6 & 7) , could any one please help me understand why it is so ?
Hi,
i am a new user for Using Eclipse with Tomcat in a project. Eventhough, i have used Tomcat alone for my certification purpose, i have not used Tomcat and Eclipse together.

now i have a web appliaction , for which i have created a project, and imported my code ( with Src (all my servlets,business objects) and web folders ( where i have ( jsps,html,web.xml) ) from CVS.

now when i click run on server on my project. i am getting 404 in the webbrowser.
Since the context root of my project is "myProject" (which is also my project name)
for this url http://localhost:8080/myProject/ i am getting 404.

note :
1)i am not getting any error on console either in tomcat startup nor after invocation.
iam getting follwing message in the console." Servlet 'fulfillment' configured successfully"

2)now under Servers directry in eclipse i could see web.xml ( which is
looks like tomcat default web.xml)

3)my web.xml in the web directory under myProject directory has welcomefile entry. and there is no entry for /myProject.

Am i missing something ??

pls help
Hi Kiaama thanks a lot for your Reply..

The i have uninstalled Tomcat ver 5.5.16 and installed 5.5.17 and the issue resloved.

thanks
Babu
Thanks a lot for Your Valueable time Ben .

i have uninstalled Tomcat Version 5.5.16 and installed Tomcat Version 5.5.17 .. its working fine .

Thanks
Babu
16 years ago
Thanks for the Replay Ben.
Sorry it was a Typo ..it was WEB-INF only..
16 years ago
Hi all,

i am getting 404 for all files in Tomcat ..

what i did is just complied the servlet and placed the class file in respective dir and placed the web.xml in Beer-v1/web-inf/
and restarted the tomcat.

when i tried to invoke the url http://localhost:8080/Beer-v1/form.html
i got 404. ( note: i have my html in beer-v1 folder).


i am Using Tomcat5.5, windows XP home , jdk1.5.0_06
just pasting what i got in localhost.log .

Jun 28, 2006 6:31:42 AM org.apache.catalina.core.ApplicationContext log
INFO: org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule: Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.balancer.rules.RequestParameterRule: Target param name: paramName / Target param value: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balancer.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]]
Jun 28, 2006 6:31:42 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Error configuring application listener of class listeners.ContextListener
java.lang.ClassFormatError: Extra bytes at the end of class file listeners/ContextListener
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1812)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:866)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1319)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1198)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3677)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4183)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:904)
at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:867)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:474)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1112)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
at org.apache.catalina.core.StandardService.start(StandardService.java:450)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:275)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Jun 28, 2006 6:31:42 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Error configuring application listener of class listeners.SessionListener
java.lang.ClassFormatError: Extra bytes at the end of class file listeners/SessionListener
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1812)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:866)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1319)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1198)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3677)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4183)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:904)
at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:867)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:474)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1112)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
at org.apache.catalina.core.StandardService.start(StandardService.java:450)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:275)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Jun 28, 2006 6:31:42 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Skipped installing application listeners due to previous error(s)

is anybody faced this issue ? if so how did you resloved it?

Thanks in Advance
Babu
16 years ago
Hi all,
while i was trying to workout Chapter3 in HFSJ .. i got following error in my tomcat. none of my previous app's working now.

what i did is just complied the servlet and placed the class file in respective dir and placed the web.xml in Beer-v1/web-inf/
and restarted the tomcat.

when i tried to invoke the url http://localhost:8080/Beer-v1/form.html
i got 404. ( note: i have my html in beer-v1 folder).


i am Using Tomcat5.5, windows XP home , jdk1.5.0_06
just pasting what i got in localhost.log .

Jun 28, 2006 6:31:42 AM org.apache.catalina.core.ApplicationContext log
INFO: org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule: Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.balancer.rules.RequestParameterRule: Target param name: paramName / Target param value: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balancer.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]]
Jun 28, 2006 6:31:42 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Error configuring application listener of class listeners.ContextListener
java.lang.ClassFormatError: Extra bytes at the end of class file listeners/ContextListener
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1812)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:866)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1319)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1198)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3677)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4183)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:904)
at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:867)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:474)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1112)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
at org.apache.catalina.core.StandardService.start(StandardService.java:450)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:275)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Jun 28, 2006 6:31:42 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Error configuring application listener of class listeners.SessionListener
java.lang.ClassFormatError: Extra bytes at the end of class file listeners/SessionListener
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1812)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:866)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1319)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1198)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3677)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4183)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:904)
at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:867)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:474)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1112)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
at org.apache.catalina.core.StandardService.start(StandardService.java:450)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:275)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Jun 28, 2006 6:31:42 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Skipped installing application listeners due to previous error(s)

Thanks
Babu
Thanks Marc and Charles for your replies .. now i got a clear idea. About role of Specs in Exam preparation.
thaax a lot
Babu
Chaminda .. its a good Move.. include me as well.
babuthannasi@yahoo.com
Hi All,
i have just started preparing SCWCD, i have Only HFSJ book and preparing from that. Just Curious to Know, how important is Servlet Specs for this Exam. or How much time i need to spend memorising these Specs?

thanks
Babu.