Giter Site home page Giter Site logo

Comments (11)

anjackson avatar anjackson commented on August 20, 2024

How exactly are you invoking JhoveView?
EDIT Oh and which version are you running?

Also, I imagine you are behind a firewall? IIRC we had some issues with JHOVE at one point where we had to cache some schemas locally to avoid hitting a remote server too hard. If you combine that dependency and some retries with some long OS and/or firewall level DNS or TCP timeouts, that might do it.

from jhove.

ross-spencer avatar ross-spencer commented on August 20, 2024

That could be it. Is there a list of locations Jhove needs to get through to? Surprising it comes up if it likely to not reach anywhere?

I just double click it. To get it running normally.

That does remind me I haven't tried from the command line.

On 20/02/2015, at 21:20, Andy Jackson [email protected] wrote:

How exactly are you invoking JhoveView?

Also, I imagine you are behind a firewall? IIRC we had some issues with JHOVE at one point where we had to cache some schemas locally to avoid hitting a remote server too hard. If you combine that dependency and some retries with some long OS and/or firewall level DNS or TCP timeouts, that might do it.


Reply to this email directly or view it on GitHub.

from jhove.

ross-spencer avatar ross-spencer commented on August 20, 2024

I ran it from the command line. I think it was helpful. Took just as long to load, but I found if I compare the XSD it is looking for:

http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd

With the error messages:

  c:\working\jhove-1_11\jhove\bin>java -jar JhoveView.jar
  [Warning] jhove.conf:6:73: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Error] jhove.conf:6:73: cvc-elt.1: Cannot find the declaration of element 'jhoveConfig'.
  [Warning] jhove.conf:7:13: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:8:19: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:9:17: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:10:14: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:11:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:12:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:14:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:15:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:17:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:18:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:20:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:21:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:23:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:24:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:26:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:27:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:29:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:30:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:32:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:33:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:34:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:36:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:37:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:39:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:40:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:42:10: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  [Warning] jhove.conf:43:11: schema_reference.4: Failed to read schema document 'http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
  Feb 21, 2015 12:50:41 PM edu.harvard.hul.ois.jhove.JhoveBase init
  SEVERE: Testing SEVERE level

Is it as simple as the XSD namespace declaration being incorrect from JHove's perspective? XS not XSD...?

<xs:schema targetNamespace="http://hul.harvard.edu/ois/xml/ns/jhove/jhoveConfig" elementFormDefault="qualified" attributeFormDefault="unqualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">

<xs:element name="jhoveConfig">

My machine can get through the schema location OK.

from jhove.

anjackson avatar anjackson commented on August 20, 2024

Are you behind a proxy? You may need to tell Java about it. (http://stackoverflow.com/questions/120797/how-do-i-set-the-proxy-to-be-used-by-the-jvm - recent JVMs are alleged to pick up the system web proxy configuration, but in my experience, you end up having to specify it manually.)

from jhove.

ross-spencer avatar ross-spencer commented on August 20, 2024

Yep, just posted some info in GitHub but then saw this so took the
opportunity to update my settings. Still the same issue when I setup the
proxy under Java network settings.

On Sat, Feb 21, 2015 at 12:58 PM, Andy Jackson [email protected]
wrote:

Are you behind a proxy? You may need to tell Java about it.


Reply to this email directly or view it on GitHub
#15 (comment).

from jhove.

anjackson avatar anjackson commented on August 20, 2024

TBH, I've never had much luck with that, and always ended up specifying the proxy on the CLI. FWIW, I just tried running like this, pointing JHove at a non-existant proxy, and got a significant (but not 10min) slowdown:

java -Dhttp.proxyHost=10.0.0.100 -Dhttp.proxyPort=8800 -jar JhoveView.jar

The xs v xsd thing should not really matter - the XML file is self-consistent (declares and uses xs). I think that's an issue with JHOVE's error reporting. Is there any chance your proxy is doing something weird when the client is not a browser? e.g. if you do this from the command line:

curl "http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd"

is the XSD file downloaded intact?

from jhove.

ross-spencer avatar ross-spencer commented on August 20, 2024

I think the important information might be from curl: curl: (7) Failed to
connect to hul.harvard.edu port 80: Timed out

So it looks like a proxy issue. Unfortunately, setting my proxy following
your outline, it doesn't seem to help either, so either way it's about a 10
minute wait.

On Sun, Feb 22, 2015 at 10:00 AM, Andy Jackson [email protected]
wrote:

TBH, I've never had much luck with that, and always ended up specifying
the proxy on the CLI. FWIW, I just tried running like this, pointing JHove
at a non-existant proxy, and got a significant (but not 10min) slowdown:

java -Dhttp.proxyHost=10.0.0.100 -Dhttp.proxyPort=8800 -jar JhoveView.jar

The xs v xsd thing should not really matter - the XML file is
self-consistent (declares and uses xs). I think that's an issue with
JHOVE's error reporting. Is there any chance your proxy is doing something
weird when the client is not a browser? e.g. if you do this from the
command line:

curl "http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd"

is the XSD file downloaded intact?


Reply to this email directly or view it on GitHub
#15 (comment).

from jhove.

ross-spencer avatar ross-spencer commented on August 20, 2024

I have managed to work around this by removing the offending lines from the JHOVE config in:

C:\Documents and Settings{user}\jhove\conf

(Windows XP)

<?xml version="1.0" encoding="UTF-8"?>
<jhoveConfig version="1.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xmlns="http://hul.harvard.edu/ois/xml/ns/jhove/jhoveConfig" xsi:schemaLocation="http://hul.harvard.edu/ois/xml/ns/jhove/jhoveConfig http://hul.harvard.edu/ois/xml/xsd/jhove/jhoveConfig.xsd">

Becomes:

<?xml version="1.0" encoding="UTF-8"?>
<jhoveConfig version="1.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

I haven't got time to investigate if JHOVE_HOME can be customised (It doesn't seem to pick up env settings in Windows at least) but this should reduce the pain for anyone with this issue.

I'm sure there is a solution somewhere, but as a workaround this doesn't seem too bad.

I'll leave this up to the team here to close and markup as appropriate if they're happy.

from jhove.

gmcgath avatar gmcgath commented on August 20, 2024

Another workaround would be to make a local copy of the schema and set the schema-location appropriately.

from jhove.

anjackson avatar anjackson commented on August 20, 2024

It's a pain that XML Schema caching isn't more fully standardised - it's different for every parser library.

I guess another option would be to disable validation in the parser? Or take the schema location out of the XML (as suggested by @ross-spencer) but still hook it in from the JAR/classpath via the Java parser code instead?

from jhove.

ross-spencer avatar ross-spencer commented on August 20, 2024

@carlwilson reviewing bugs today, I think this can likely be closed now since the latest versions.

from jhove.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.