• 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:
  • Tim Cooke
  • Campbell Ritchie
  • paul wheaton
  • Ron McLeod
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:

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

 
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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
 
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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.
 
iyappan sankaran
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Jared. Now it works fine.
 
reply
    Bookmark Topic Watch Topic
  • New Topic