Hi,
Add a service provider file in META-INF/services in your own jar. This file would be named like tika's own, but only list your parser. SPI (the technique behind the whole META-INF/services) is collecting all those files in the classpath and make all parsers listed in them available. The same happens in Lucene 4.0 (not yet released), it will make it possible to plug in any indexing codec just by providing the JAR file with the correct SPI metadata. ----- Uwe Schindler H.-H.-Meier-Allee 63, D-28213 Bremen http://www.thetaphi.de <http://www.thetaphi.de/> eMail: [email protected] From: ola nowak [mailto:[email protected]] Sent: Thursday, January 05, 2012 1:47 PM To: [email protected] Subject: External parser in a jar file Hi, I've created an external parser. I added some classes to org.apache.tika.parser.xml package and listed my parser in tika-parsers/src/main/resources/META-INF/services/org.apache.tika.parser.Par ser file and my custom mime type in custom-mimetypes.xml. I builded all and it works :) Now I have a question if there is a posibility to tell tika to use this parser without messing in its sources? I'll be using it in Solr, so I would like just to use orginal tika's jars and probably some jar with my classes. Is this even possible? Regards, Alex
