incubator-connectors-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From conflue...@apache.org
Subject [CONF] Apache Connectors Framework > How to Write an Output Connector
Date Mon, 18 Oct 2010 18:57:00 GMT
Space: Apache Connectors Framework (https://cwiki.apache.org/confluence/display/CONNECTORS)
Page: How to Write an Output Connector (https://cwiki.apache.org/confluence/display/CONNECTORS/How+to+Write+an+Output+Connector)
Comment: https://cwiki.apache.org/confluence/display/CONNECTORS/How+to+Write+an+Output+Connector?focusedCommentId=24183424#comment-24183424

Comment added by Farzad:
---------------------------------------------------------------------

I was looking at the code for DBInterfacePostgreSQL in org.apache.manifoldcf.core.database
and looks like it is not setup to handle multiple primary keys.  Aren't primary keys suppose
to be listed together as a comma separated list?

In reply to a comment by Farzad:
Error definging multiple primary keys.  So I'm using the org.apache.manifoldcf.core.interfaces.ColumnDescription
class to setup the db tables.  If I specify two columns to be primary keys then I get the
following error.  It makes it sound like I can have multiple keys if I define the table correctly,
ie. for table XX not allowed, as if allowed for table YY.  I didn't see any documentation
to help me understand it.  Any ideas?

C:\Program Files\Apache\apache-acf\dupfinder\example>java -jar start.jar >> output.txt
Configuration file successfully read
Successfully unregistered all output connectors
Successfully unregistered all authority connectors
Successfully unregistered all repository connectors
Successfully registered output connector 'org.apache.manifoldcf.agents.output.solr.SolrConnector'
org.apache.manifoldcf.core.interfaces.ManifoldCFException: Database exception: Exception doing
query: ERROR: multiple primary keys for table "filedata" are not allowed
        at org.apache.manifoldcf.core.database.Database.executeViaThread(Database.java:421)
        at org.apache.manifoldcf.core.database.Database.executeUncachedQuery(Database.java:449)
        at org.apache.manifoldcf.core.database.Database$QueryCacheExecutor.create(Database.java:1091)
        at org.apache.manifoldcf.core.cachemanager.CacheManager.findObjectsAndExecute(CacheManager.java:144)
        at org.apache.manifoldcf.core.database.Database.executeQuery(Database.java:167)
        at org.apache.manifoldcf.core.database.DBInterfacePostgreSQL.performModification(DBInterfacePostgreSQL.java:586)
        at org.apache.manifoldcf.core.database.DBInterfacePostgreSQL.performCreate(DBInterfacePostgreSQL.java:255)
        at org.apache.manifoldcf.core.database.BaseTable.performCreate(BaseTable.java:111)
        at org.apache.manifoldcf.agents.output.dupfinder.DataManager.install(DataManager.java:57)
        at org.apache.manifoldcf.agents.output.dupfinder.DupFinderConnector.install(DupFinderConnector.java:98)
        at org.apache.manifoldcf.agents.interfaces.OutputConnectorFactory.install(OutputConnectorFactory.java:51)
        at org.apache.manifoldcf.agents.outputconnmgr.OutputConnectorManager.registerConnector(OutputConnectorManager.java:169)
        at org.apache.manifoldcf.jettyrunner.ManifoldCFJettyRunner.main(ManifoldCFJettyRunner.java:348)
Caused by: org.postgresql.util.PSQLException: ERROR: multiple primary keys for table "filedata"
are not allowed
        at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1548)
        at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1316)
        at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:191)
        at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:452)
        at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:337)
        at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:329)
        at org.apache.manifoldcf.core.database.Database.execute(Database.java:526)
        at org.apache.manifoldcf.core.database.Database$ExecuteQueryThread.run(Database.java:381)

C:\Program Files\Apache\apache-acf\dupfinder\example>



Change your notification preferences: https://cwiki.apache.org/confluence/users/viewnotifications.action

Mime
View raw message