aspose file tools*
The moose likes JBoss/WildFly and the fly likes javax.servlet.ServletException: non-HTTP request or response Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "javax.servlet.ServletException: non-HTTP request or response" Watch "javax.servlet.ServletException: non-HTTP request or response" New topic
Author

javax.servlet.ServletException: non-HTTP request or response

Ankit Varshney
Greenhorn

Joined: Aug 01, 2008
Posts: 29
Hello Friends

I am using J BOSS 5.0.0 GA for deploying my ear file.Its deployed successfully but while running the project its shown the exception.
The server log is shown below..




Please help me out.How to solve it


Have a nice time... <br />Ankit Kumar Varshney
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 10266
    
168

It was bug which got fixed in JBossAS-5.0.1 GA. I would recommend that you upgrade to the latest 5.1.0 GA version of JBoss AS since it has many bug fixes. Here are the details about this specific issue:

Forum thread 1

Related thread

JBAS-6478


[My Blog] [JavaRanch Journal]
Ankit Varshney
Greenhorn

Joined: Aug 01, 2008
Posts: 29
hello Sir,

I also have tried in jboss-5.1.0.GA but its giving same error..

What should i do???

Its very urgent for me

Bill Burke Jboss
Greenhorn

Joined: Jun 16, 2009
Posts: 1
I had the same problem. Fixed it by removing servlet-api jar from my WAR file.
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 10266
    
168

"Bill Burke Jboss"

Please click the "My Private Messages" link (at the top of this page) for a message from JavaRanch.
narayanarao gare
Greenhorn

Joined: Mar 05, 2010
Posts: 2
i too faced the same issue. i tried even removing the servlet-api jar but no luck........ can any one help me out on this?
Peter Johnson
author
Bartender

Joined: May 14, 2008
Posts: 5843
    
    7

narayanarao, welcome to Java Ranch!

Please ShowSomeEffort. Saying "me too" on someone else's post is usually is not sufficient. You should open a new post and TellTheDetails. For example, are you deploying an EAR? Are you using JBoss AS 5.0.0.GA? What are the contents of your EAR?


JBoss In Action
Janmajay Vishnu
Greenhorn

Joined: Sep 05, 2010
Posts: 1
Explaination:
Normally all these kind of problems are cause dues to multiple version of same packages.

For example, In my eclipse environment, I have jsp-api and servlet-api of some version (lower then 2.5 and 2.0, respectively).

At runtime jboss compiles the jsp page and tries to invoke methods from newer version (Don't ask me which, since I have not dug in that line).



Solution:
Remove servlet-api.jar and jsp-api.jar

TIP
Whenever I run into these kind of issues, I rip apart the project by striping off all the jars. Then add them (in groups like spring, velocity, commons, etc.) one by one based on Class not found exception. Once my project runs, I know the offenders and I blacklist them by putting them in exclude tag in ivy or removing them from web-inf/lib, etc.
Its worth the time because its something I don't do everyday and keeps my project.
Yedder Isran Nallamilli
Greenhorn

Joined: Mar 12, 2012
Posts: 1
Yes, this runtime exception is absolutely due to conflicts in jar files.
I had servlet jar in my WEB-INF lib directory, which is added to build path to let the class visible to compile the dependecy files and another in my JBoss [Trinity] 4.2.1.GA server lib directory. When I ran the ear the application was running fine but when I ran the application on the my production server JBoss_5_1_0_GA it beautifully kissed that exception.
There can be two possibilties of error,
1) The jboss
2) The differences version of servlet jar files in EAR file and one in server directory.
 
 
subject: javax.servlet.ServletException: non-HTTP request or response