From open-jpa-dev-return-4209-apmail-incubator-open-jpa-dev-archive=incubator.apache.org@incubator.apache.org Mon May 21 21:58:39 2007 Return-Path: Delivered-To: apmail-incubator-open-jpa-dev-archive@locus.apache.org Received: (qmail 19490 invoked from network); 21 May 2007 21:58:38 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 21 May 2007 21:58:38 -0000 Received: (qmail 84541 invoked by uid 500); 21 May 2007 21:58:43 -0000 Delivered-To: apmail-incubator-open-jpa-dev-archive@incubator.apache.org Received: (qmail 84517 invoked by uid 500); 21 May 2007 21:58:43 -0000 Mailing-List: contact open-jpa-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: open-jpa-dev@incubator.apache.org Delivered-To: mailing list open-jpa-dev@incubator.apache.org Received: (qmail 84476 invoked by uid 99); 21 May 2007 21:58:43 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 21 May 2007 14:58:43 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 21 May 2007 14:58:36 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id A12F2714043 for ; Mon, 21 May 2007 14:58:16 -0700 (PDT) Message-ID: <20982517.1179784696657.JavaMail.jira@brutus> Date: Mon, 21 May 2007 14:58:16 -0700 (PDT) From: "Patrick Linskey (JIRA)" To: open-jpa-dev@incubator.apache.org Subject: [jira] Assigned: (OPENJPA-130) Streaming LOB support In-Reply-To: <20966676.1170876485539.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/OPENJPA-130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Patrick Linskey reassigned OPENJPA-130: --------------------------------------- Assignee: Patrick Linskey > Streaming LOB support > --------------------- > > Key: OPENJPA-130 > URL: https://issues.apache.org/jira/browse/OPENJPA-130 > Project: OpenJPA > Issue Type: New Feature > Components: datacache, jdbc, jpa, kernel > Reporter: Patrick Linskey > Assigned To: Patrick Linskey > Fix For: 1.1.0 > > > BLOB and CLOB fields can only be mapped in their entirety in OpenJPA. It would be nice to support fields of type java.io.InputStream (for BLOBs) and java.io.Reader (for CLOBs). > The usage pattern could look like so: > @Entity > public class Employee { > ... > private InputStream photoStream; > public void setPhotoStream(InputStream in) { > photoStream = in; > } > public InputStream getPhotoStream() { > return photoStream; > } > } > So, when the user wants to provide a stream, she will set the InputStream field, and when the user wants to obtain a stream, she will use the field. > The behavior of such an implementation would be a bit different than how other fields work, in that if the user set the stream and then consumed it within a single transaction, presumably no data would be written out to the database at commit time. But that is the nature of streams. > (FTR, I think that I stole this idea from an email Craig Russell sent out years ago.) -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.