wood burning stoves 2.0*
The moose likes JNLP and Web Start and the fly likes JNLP Error: Bad MIME type returned from server when accessing resource: Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JNLP and Web Start
Bookmark "JNLP Error: Bad MIME type returned from server when accessing resource: " Watch "JNLP Error: Bad MIME type returned from server when accessing resource: " New topic
Author

JNLP Error: Bad MIME type returned from server when accessing resource:

iyappan sankaran
Ranch Hand

Joined: Aug 11, 2003
Posts: 58
Hi
I encounterd an error . i provided all the details .
please help me.

General:

An error occurred while launching/running the application.



Category: Download Error

Bad MIME type returned from server when accessing resource: http://localhost/Sample.jnlp - text/html

Lanuch File :
<?xml version="1.0" encoding="iso-8859-1"?>
<jnlp
spec="1.0+"
codebase="http://localhost/"
href="Sample.jnlp">
<information>
<title>Manager</title>
<vendor>Iyappan</vendor>
<description>Sample Application</description>
</information>
<security>
<all-permissions/>
</security>
<resources>
<j2se version="1.5+" />
<jar href= "Iyappan.jar" />
</resources>
<application-desc main-class="Sample">
<argument>-UserName</argument>
<argument>Administrator</argument>
<argument>-UserRole</argument>
<argument>Administrator</argument>
</application-desc>
</jnlp>


Exception:

JNLPException[category: Download Error : Exception: null : LaunchDesc: null ]

at com.sun.javaws.cache.DownloadProtocol.doDownload(Unknown Source)

at com.sun.javaws.cache.DownloadProtocol.isLaunchFileUpdateAvailable(Unknown Source)

at com.sun.javaws.LaunchDownload.getUpdatedLaunchDesc(Unknown Source)

at com.sun.javaws.Launcher.downloadResources(Unknown Source)

at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)

at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)

at com.sun.javaws.Launcher.run(Unknown Source)

at java.lang.Thread.run(Unknown Source)




Remedy I followed:

Configured the Web server to use the Java Web Start MIME type by adding Mime entry in mime.types file in conf folder in apache server.

The entry is “application/x-java-jnlp-file jnlp”.

Still I got the same error.


Thanks
Iyappan
Jared Cope
Ranch Hand

Joined: Aug 18, 2004
Posts: 243
Hi,

I've had a problem like this before. Steps that worked for me were:

1. Make that mime type addition and restart webserver
2. Clear file cache in the browser that downloaded the .jnlp file (it will still have a copy with the mine type set as text/html)
3. Try downloading again.

Hope that works for you.

Cheers, Jared.


SCJP 1.4 91%, SCJP 1.5 88%, SCJD B&S
iyappan sankaran
Ranch Hand

Joined: Aug 11, 2003
Posts: 58
Thanks Jared. Now it works fine.
 
Don't get me started about those stupid light bulbs.
 
subject: JNLP Error: Bad MIME type returned from server when accessing resource:
 
Similar Threads
JWS Download Error
javax.jnlp
Please Help me Out.....Where I am going Wrong
JNLP error
JNLPFile error in webstart