wood burning stoves 2.0*
The moose likes MongoDB and the fly likes MongoDB in conjuction with JPA Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Databases » MongoDB
Bookmark "MongoDB in conjuction with JPA" Watch "MongoDB in conjuction with JPA" New topic
Author

MongoDB in conjuction with JPA

Sai Hegde
security forum advocate
Ranch Hand

Joined: Oct 26, 2010
Posts: 199
    
    1

For a project that I am working on, we have requirements where we are supposed to replicate data from DB2 to mongo. Now the object that is returned back from DB2 is about 70M (an eagerly loaded object) with multiple clobs and blobs. While I am looking into GridFS for sharding it before I'd save it to mongo, I wonder if there were any suggested ways of doing this?
Rick Copeland
author
Greenhorn

Joined: Apr 09, 2013
Posts: 17
    
    5
I suppose it depends on how you want to use the object once it's in MongoDB. You certainly can choose to just shove everything into a GridFS "file", but you lose query-ability (a GridFS file should be treated like a BLOB would be in a RDBMS).

If the object is over 70MB and you don't want to decompose it structurally, you are going to need to store it in GridFS, since MongoDB documents are limited to 16MB each.

Hope that helps!


My book: [MongoDB Applied Design Patterns]
My blog: [Just a Little Python]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: MongoDB in conjuction with JPA
 
Similar Threads
How do i install the MongoDB drivers in Netbeans 7.3 on a windows platform
DB2 Stored procedures written in Java
How to give in the context .xml for a MongoDb?..
Connection Pooling Morphia Datasource
JNDI - Object lookup on another AppServer