Metacat replication fails for datafiles with "&" in the filename
When troubleshooting SANParks-SAEON, we encountered errors with the documentInfo parser on the target machine:
judithk.1128.1 has the filename: "KamathPL_ZebraSampling&GenotypeData.txt"
knb 20120904-22:03:59: [ERROR]: ReplicationHandler.handleSingleDataFile - 6 Failed to write data file judithk.1128.1 into xml_documents from dataknp.sanparks.org/sanparks/servlet/replication because The reference to entity "GenotypeData.txt" must end with the ';' delimiter.
judithk.1223.1: "KNPEle & Buff Census 2007 Report.pdf"
knb 20120906-04:10:23: [ERROR]: ReplicationHandler.handleSingleDataFile - 9 Failed to write data file judithk.1223.1 into xml_documents from dataknp.sanparks.org/sanparks/servlet/replication because The entity name must immediately follow the '&' in the entity reference. [ReplicationLogging]
#1 Updated by ben leinfelder over 8 years ago
I've fixed this and wrote a simple test that exercises the docInfo parser. I just wrapped the content of the 'docname' field in CDATA tags so that any reserved characters do not cause errors.
I'd like to include it in the 2.0.4 release, but we are in the midst of some somewhat-final testing. Action TBD.