Return-Path: Delivered-To: apmail-incubator-connectors-commits-archive@minotaur.apache.org Received: (qmail 44868 invoked from network); 13 Oct 2010 17:08:21 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 13 Oct 2010 17:08:21 -0000 Received: (qmail 47870 invoked by uid 500); 13 Oct 2010 17:08:21 -0000 Delivered-To: apmail-incubator-connectors-commits-archive@incubator.apache.org Received: (qmail 47810 invoked by uid 500); 13 Oct 2010 17:08:21 -0000 Mailing-List: contact connectors-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: connectors-dev@incubator.apache.org Delivered-To: mailing list connectors-commits@incubator.apache.org Received: (qmail 47803 invoked by uid 99); 13 Oct 2010 17:08:21 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Oct 2010 17:08:21 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Oct 2010 17:08:20 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o9DH80o9020256 for ; Wed, 13 Oct 2010 17:08:00 GMT Date: Wed, 13 Oct 2010 13:08:00 -0400 (EDT) From: confluence@apache.org To: connectors-commits@incubator.apache.org Message-ID: <31064729.175.1286989680034.JavaMail.confluence@thor> Subject: [CONF] Apache Connectors Framework > How to Write an Output Connector MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Auto-Submitted: auto-generated 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=24182874#comment-24182874 Comment added by Karl Wright: --------------------------------------------------------------------- The best answer I can give right at the moment is to look at what the web connector does for tables.  You will find that it creates two of them.  Follow the same conventions and you should be OK.  Naming is up to you, but obviously a good practice is to use a prefix that is likely to keep your table name from colliding with other tables from other connectors, or from future versions of the framework.  If or when there is a ManifoldCF book, be assured that this topic will be covered in depth.\\ In reply to a comment by Farzad: I'd like to create an output connector where I can detect duplicate files (documents) in the repository. My thought is to store a hashsum value for each document, SHA-512, and store that in a table and set it as a primary key. Subsequent insert with the same value would be rejected indicating a duplicate. I read connectors are allowed to have their own tables. What would the table name be? I issue SQL over JDBC to modify table data? How do you establish a connection to the db? Any other thoughts about my approach? Thanks! Change your notification preferences: https://cwiki.apache.org/confluence/users/viewnotifications.action