• 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

500 servletException

 
Ranch Hand
Posts: 98
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I have the following problem:

500 Servlet Exception

/usr/local/resin-3.0.4/diggov/dgrc/WEB-INF/classes/com/dgo/common/DAO/RegistrationDAO_original.java:16:
class RegistrationDAO is public, should be declared in a file named RegistrationDAO.java
public class RegistrationDAO {
^
1 error

Why is this happening? I did copy the contents back from the RegistrationDAO_original.java to RegistrationDAO.java and did run the follwoing command:
javac -classpath /usr/local/resin-3.0.4/lib/servlet.jar com/dgo/common/DAO/RegistrationDAO.java
and the class file seems to be updated...checked it using ls -l
any help will be appreciated.
Thanks
Preetham
 
Bartender
Posts: 10336
Hibernate Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You are probably still deploying the old class too. Clear out the temporary directories, delete RegistrationDAO_original.java and redeploy.
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

As you are having 2 public classes you are getting the error. Try to rename the "public class" declaration in the old file.

Hope this helps.

Thanks
Kalyani
 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If the class name with public key word and the filename you are saving is not matching.....

Regards,
Reddy
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Remove the class and redeploy it.
 
Can you really tell me that we aren't dealing with suspicious baked goods? And then there is this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic