[ https://issues.apache.org/jira/browse/TIKA-1107?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13632332#comment-13632332 ]
Jorge Urdaneta commented on TIKA-1107: -------------------------------------- looks like we're getting a parser for mimetype 'application/octet-stream'. maybe that's the reason. a bad file type detect > Can't parse velocity file > ------------------------- > > Key: TIKA-1107 > URL: https://issues.apache.org/jira/browse/TIKA-1107 > Project: Tika > Issue Type: Bug > Affects Versions: 1.3 > Environment: openjdk-1.7.0_17 > Reporter: Jorge Urdaneta > Attachments: events-detail.vtl > > > When I parse some VTL (velocity) files I get an error > 2013-04-15 22:39:56,488 ERROR com.dotcms.tika.TikaUtils - Could not parse > file metadata for file : > /home/jorgeu/dotcms/dotcms/tomcat/webapps/../../dotCMS/assets/5/a/5a533adc-818f-4f55-a448-622bb90b576c/fileAsset/events-detail.vtl > org.apache.tika.exception.TikaException: XML parse error > at org.apache.tika.parser.xml.XMLParser.parse(XMLParser.java:78) > at > org.apache.tika.parser.CompositeParser.parse(CompositeParser.java:242) > at > org.apache.tika.parser.CompositeParser.parse(CompositeParser.java:242) > at > org.apache.tika.parser.AutoDetectParser.parse(AutoDetectParser.java:120) > at com.dotcms.tika.TikaUtils.getMetaDataMap(TikaUtils.java:41) > at com.dotcms.tika.TikaUtils.getMetaDataMap(TikaUtils.java:85) > at > com.dotmarketing.portlets.fileassets.business.FileAssetAPIImpl.getMetaDataMap(FileAssetAPIImpl.java:202) > at > com.dotcms.content.elasticsearch.business.ESContentletAPIImpl.checkin(ESContentletAPIImpl.java:2409) > at > com.dotcms.content.elasticsearch.business.ESContentletAPIImpl.checkin(ESContentletAPIImpl.java:1946) > at > com.dotmarketing.portlets.contentlet.business.ContentletAPIInterceptor.checkin(ContentletAPIInterceptor.java:169) > at > com.dotmarketing.portlets.contentlet.business.web.ContentletWebAPIImpl._saveWebAsset(ContentletWebAPIImpl.java:495) > at > com.dotmarketing.portlets.contentlet.business.web.ContentletWebAPIImpl.saveContent(ContentletWebAPIImpl.java:129) > at > com.dotmarketing.portlets.contentlet.ajax.ContentletAjax.saveContent(ContentletAjax.java:1321) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:601) > at > org.directwebremoting.impl.CreatorModule$1.doFilter(CreatorModule.java:229) > at > org.directwebremoting.impl.CreatorModule.executeMethod(CreatorModule.java:241) > at > org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:379) > at > org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:332) > at > org.directwebremoting.dwrp.BaseCallHandler.handle(BaseCallHandler.java:104) > at > org.directwebremoting.servlet.UrlProcessor.handle(UrlProcessor.java:120) > at org.directwebremoting.servlet.DwrServlet.doPost(DwrServlet.java:141) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:637) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > at > org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:404) > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > at com.dotmarketing.filters.CMSFilter.doFilter(CMSFilter.java:122) > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > at > com.dotmarketing.filters.AutoLoginFilter.doFilter(AutoLoginFilter.java:61) > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > at > com.dotmarketing.filters.CacheImagesFilter.doFilter(CacheImagesFilter.java:47) > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > at > com.dotmarketing.cms.urlmap.filters.URLMapFilter.doFilter(URLMapFilter.java:87) > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > at > com.dotmarketing.filters.TimeMachineFilter.doFilter(TimeMachineFilter.java:129) > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > at > com.dotmarketing.filters.CharsetEncodingFilter.doFilter(CharsetEncodingFilter.java:140) > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > at > org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) > at > org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) > at > org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:465) > at > org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) > at > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) > at > org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) > at > org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:555) > at > org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298) > at > org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:852) > at > org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588) > at > org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489) > at java.lang.Thread.run(Thread.java:722) > Caused by: org.xml.sax.SAXParseException; lineNumber: 9; columnNumber: 14; > The entity name must immediately follow the '&' in the entity reference. > at > org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown > Source) > at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown Source) > at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) > at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) > at org.apache.xerces.impl.XMLScanner.reportFatalError(Unknown Source) > at > org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEntityReference(Unknown > Source) > at > org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown > Source) > at > org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown > Source) > at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) > at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) > at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) > at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) > at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown > Source) > at org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown Source) > at javax.xml.parsers.SAXParser.parse(SAXParser.java:195) > at org.apache.tika.parser.xml.XMLParser.parse(XMLParser.java:72) > ... 60 more -- 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