SMIL impl bundle fails to build in specific circumstances

Steps to reproduce

Steps to reproduce:
1. Disconnect from the internet, but do not disconnect in such a way that your building system knows it has disconnected. Something like unplugging the uplink from your switch, but leaving the switch plugged in ought to do.
2. Build the smil-impl bundle
3.

Actual Results:
[INFO] -------------------------------------------------------
[INFO] T E S T S
[INFO] -------------------------------------------------------
[INFO] Running org.opencastproject.smil.impl.SmilResponseImplTest
[INFO] Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.274 s - in org.opencastproject.smil.impl.SmilResponseImplTest
[INFO] Running org.opencastproject.smil.impl.SmilServiceImplTest
[ERROR] Tests run: 11, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 0.072 s <<< FAILURE! - in org.opencastproject.smil.impl.SmilServiceImplTest
[ERROR] testFromXml(org.opencastproject.smil.impl.SmilServiceImplTest) Time elapsed: 0.054 s <<< ERROR!
org.opencastproject.smil.api.SmilException: Parsing SMIL document failed.
at org.opencastproject.smil.impl.SmilServiceImplTest.testFromXml(SmilServiceImplTest.java:425)
Caused by: javax.xml.bind.UnmarshalException
at org.opencastproject.smil.impl.SmilServiceImplTest.testFromXml(SmilServiceImplTest.java:425)
Caused by: java.net.UnknownHostException: www.w3.org
at org.opencastproject.smil.impl.SmilServiceImplTest.testFromXml(SmilServiceImplTest.java:425)

[ERROR] testRemoveSmilElement(org.opencastproject.smil.impl.SmilServiceImplTest) Time elapsed: 0.012 s <<< ERROR!
org.opencastproject.smil.api.SmilException: Parsing SMIL document failed.
at org.opencastproject.smil.impl.SmilServiceImplTest.testRemoveSmilElement(SmilServiceImplTest.java:395)
Caused by: javax.xml.bind.UnmarshalException
at org.opencastproject.smil.impl.SmilServiceImplTest.testRemoveSmilElement(SmilServiceImplTest.java:395)
Caused by: java.net.UnknownHostException: www.w3.org
at org.opencastproject.smil.impl.SmilServiceImplTest.testRemoveSmilElement(SmilServiceImplTest.java:395)

Expected Results:
Not resolving domain names during the build!

Workaround (if any):

Activity

Show:
Greg Logan
December 22, 2017, 7:53 PM

Note: I've seen similar issue elsewhere in the codebase, but I don't remember where offhand.

James Perrin
August 6, 2019, 3:48 PM

The doctype contains a url for the dtd that is being resolved. However it uses http and it appears that the http server are not always available even to redirect to https.

www.w3.org is using strict-transport-security: ... preload in the it's header, this means that browser's "know" that via a list from google that this site should only be accessed via https it never tries to http even to be redirected. Hence they can drop handling http. Obvs java.net does not know this.

thankfully actually smil files don't include the dtd and the best soln is to remove the doctype all together from the test smil

Assignee

James Perrin

Reporter

Greg Logan

Severity

Build Error

Tags (folksonomy)

None

Components

Affects versions

Priority

Major
Configure