Skip to main content

500 error with really simple web app

2 replies [Last post]
jimcpl
Offline
Joined: 2008-04-12
Points: 0

Hi,

I am just getting started with GlassFish, and just installed it on Windows 2003, and updated it.

The GlassFish version is "GlassFish Server Open Source Edition 3.1.1 (build 12)", and it *seems* to be running ok.

I then tried to deploy and enable a simple web app/WAR file that basically contains just a "hello world" index.jsp. The GlassFish admin shows it as enabled.

However, when I try to access the web app (http://glassfish:8080/BasicAuthen), I get a 500 error, but the server.log doesn't seem to show any errors, so I'm not sure what the problem is, or oow to rectify it.

Can anyone tell me how to go about diagnosing this?

Thanks,

Jim

P.S. Here's the index.jsp:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"

"http://www.w3.org/TR/html4/loose.dtd">

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

<title>JSP Page</title>

</head>

<body>

<h1>Hello World!</h1>

</body>

</html>

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
oleksiys
Offline
Joined: 2006-01-25
Points: 0

Hi,

can you pls. create an issue
http://java.net/jira/browse/GLASSFISH

and attach your war file w/ instructions on how to reproduce the problem?

Thanks.

WBR,
Alexey.

On 01/09/2012 03:25 AM, forums@java.net wrote:
> Hi,
>
> I am just getting started with GlassFish, and just installed it on
> Windows
> 2003, and updated it.
>
> The GlassFish version is "GlassFish Server Open Source Edition 3.1.1
> (build
> 12)", and it *seems* to be running ok.
>
> I then tried to deploy and enable a simple web app/WAR file that
> basically
> contains just a "hello world" index.jsp. The GlassFish admin shows it as
> enabled.
>
> However, when I try to access the web app
> (http://glassfish:8080/BasicAuthen), I get a 500 error, but the
> server.log
> doesn't seem to show any errors, so I'm not sure what the problem is,
> or oow
> to rectify it.
>
> Can anyone tell me how to go about diagnosing this?
>
> Thanks,
>
> Jim
>
>
> --
>
> [Message sent by forum member 'jimcpl']
>
> View Post: http://forums.java.net/node/881424
>
>

jimcpl
Offline
Joined: 2008-04-12
Points: 0

Hi Alexey,

I must've messed up, because I solved my problem, and thought that I had posted about the resolution, but for some reason, my 2nd post didn't show up here :(.

The reason that I'm trying to work with GlassFish is that I am going to be trying the integration of GlassFish with OAM. The WAR that I was trying was an example web app, BasicAuthen.war, from here: http://www.oracle.com/technetwork/middleware/glassfish/documentation/glassfishoamsecurityprovider-170277.html, and I had deployed that to the GlassFish, mainly just to check that the GlassFish was working.

What I didn't realize was that the sun-web.xml file had some attributes in it that referenced the OAM security provider, which I hadn't yet deployed to GlassFish, and i think that was causing a NullPointerException whenever I accessed /BasicAuthen. After I turned up the Logger logging level on the server-config to FINER, I could see the exception.

After I (temporarily) removed those attributes from the sun-web.xml, and re-deployed the WAR, the web app worked fine.

Thanks,

Jim

P.S. Just figured out why my earlier reply didn't appear. I had not realized that there was a CAPTCHA for posting :)...