[ https://issues.apache.org/jira/browse/SOLR-1675?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Matt Inger updated SOLR-1675: ----------------------------- Attachment: SqlArrayTransformer.java Attaching the transformer class for transforming the javax.sql.Array instance to a java.lang.Object[] instance for a multi valued field. > Placing Custom Transform in example/lib directory does not work properly > ------------------------------------------------------------------------ > > Key: SOLR-1675 > URL: https://issues.apache.org/jira/browse/SOLR-1675 > Project: Solr > Issue Type: Bug > Components: contrib - DataImportHandler > Affects Versions: 1.4 > Reporter: Matt Inger > Priority: Blocker > Attachments: SqlArrayTransformer.java > > > I have created a Custom transformer for transforming a javax.sql.Array > instance into a java.lang.Object[] value, and placed it in the example/lib > directory. I then configured the transformer appropriately in my > db-data-config.xml: > {code} > <entity ... > transformer="org.apache.solr.handler.dataimport.SqlArrayTransformer" > {code} > However, when i try to actually index my documents, i get the following error > in the console: > {code} > org.apache.solr.handler.dataimport.DataImportHandlerException: > java.lang.NoClassDefFoundError: org/apache/solr/handler/dataimport/Transformer > at > org.apache.solr.handler.dataimport.DocBuilder.buildDocument(DocBuilder.java:424) > at > org.apache.solr.handler.dataimport.DocBuilder.doFullDump(DocBuilder.java:242) > at > org.apache.solr.handler.dataimport.DocBuilder.execute(DocBuilder.java:180) > at > org.apache.solr.handler.dataimport.DataImporter.doFullImport(DataImporter.java:331) > at > org.apache.solr.handler.dataimport.DataImporter.runCmd(DataImporter.java:389) > at > org.apache.solr.handler.dataimport.DataImporter$1.run(DataImporter.java:370) > Caused by: java.lang.NoClassDefFoundError: > org/apache/solr/handler/dataimport/Transformer > {code} > It seems there is some issue with the classloader going on here, and the only > solution to this problem seems to be to find the exploded web application in > the "work" directory, and place the .jar file for my transformer in the > WEB-INF/lib directory there. My guess is that the classloader for the custom > transformer class is not using the web application's class loader as it's > parent classloader, and as a result, the Transformer class can't be found. > I believe I tried this in 1.5-dev as well and had no success either. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.