You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@karaf.apache.org by "Jean-Baptiste Onofré (JIRA)" <ji...@apache.org> on 2012/11/29 21:48:58 UTC

[jira] [Assigned] (KARAF-2040) karaf-cave throws an exception and stops scanning if jsoup reads an unsupported mime type

     [ https://issues.apache.org/jira/browse/KARAF-2040?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jean-Baptiste Onofré reassigned KARAF-2040:
-------------------------------------------

    Assignee: Jean-Baptiste Onofré
    
> karaf-cave throws an exception and stops scanning if jsoup reads an unsupported mime type
> -----------------------------------------------------------------------------------------
>
>                 Key: KARAF-2040
>                 URL: https://issues.apache.org/jira/browse/KARAF-2040
>             Project: Karaf
>          Issue Type: Bug
>          Components: cave-repository
>    Affects Versions: cave-3.0.0
>         Environment: All
>            Reporter: Don Corley
>            Assignee: Jean-Baptiste Onofré
>             Fix For: cave-3.0.0
>
>         Attachments: fix_jsoup_scan.patch
>
>
> karaf-cave throws an exception and stops scanning if jsoup reads an unsupported mime type
> For example, if your type the following commands into karaf:
> karaf@root> features:addurl mvn:org.apache.karaf.cave/apache-karaf-cave/3.0.0-SNAPSHOT/xml/features
> karaf@root> features:install cave-obr-server
> karaf@root> cave:create-repository sonatype
> karaf@root> cave:proxy-repository sonatype http://repo.maven.apache.org/maven2/org/sonatype/nexus/capabilities/nexus-capabilities-testsuite-helper/2.1/
> Cave will throw the following error:
> org.jsoup.UnsupportedMimeTypeException: Unhandled content type. Must be text/*, application/xml, or application/xhtml+xml. Mimetype=application/zip, URL=http://repo.maven.apache.org/maven2/org/sonatype/nexus/capabilities/nexus-capabilities-testsuite-helper/2.1/nexus-capabilities-testsuite-helper-2.1-bundle.zip
> 	at org.jsoup.helper.HttpConnection$Response.execute(HttpConnection.java:436)[174:org.jsoup:1.7.1]
> 	at org.jsoup.helper.HttpConnection$Response.execute(HttpConnection.java:393)[174:org.jsoup:1.7.1]
> 	at org.jsoup.helper.HttpConnection.execute(HttpConnection.java:159)[174:org.jsoup:1.7.1]
> 	at org.jsoup.helper.HttpConnection.get(HttpConnection.java:148)[174:org.jsoup:1.7.1]
> 	at org.apache.karaf.cave.server.storage.CaveRepositoryImpl.proxyHttp(CaveRepositoryImpl.java:253)[176:org.apache.karaf.cave.server.storage:3.0.0.SNAPSHOT]
> 	at org.apache.karaf.cave.server.storage.CaveRepositoryImpl.proxyHttp(CaveRepositoryImpl.java:260)[176:org.apache.karaf.cave.server.storage:3.0.0.SNAPSHOT]
> To fix this, just catch the jsoup exception and ignore the file.
> Patch included.
> Thanks.
> Don Corley

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira