Community
Participate
Working Groups
Build Identifier: 1.0 It would be nice to have something like OpenJPA's LOB streaming (http://openjpa.apache.org/builds/latest/docs/manual/ref_guide_mapping_jpa.html#ref_guide_streamsupport) in EclipseLink, too. We got large files that shouldn't be loaded into memory completely. They are only read from the file system and stored into the database and later retrieved from the database and written to the file system. Declaring and annotating a field of type InputStream or Reader where only a buffer is held in memory would be a good approach from the user's point of view. Reproducible: Always
Here is the link to the current OpenJPA. http://openjpa.apache.org/builds/2.2.0/apache-openjpa/docs/manual.html#ref_guide_streamsupport The OpenJPA implementation uses a proprietary annotation and persists either an InputStream or a Reader. Hibernate also supports streams with JPA. See the information at the following locations: http://docs.jboss.org/hibernate/core/4.0/manual/en-US/html_single/ http://docs.jboss.org/ejb3/docs/tutorial/1.0.7/html/Blob_and_Clob_support_in_EJB3.html The Hibernate approach is to support persisting java.sql.Blob and java.sql.Clob types. Their API includes a helper createBlob method. http://docs.jboss.org/hibernate/orm/3.5/api/org/hibernate/Hibernate.html
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink