persistence

ORMs that work with complex .Net generic objects (e.g. nested List<...>, etc)?

I am just starting to model the data for a new project, which must be persistable. Looks like the most natural OO model will have lots of nested .Net generics. Lists of objects, and these objects will also contain Lists of other generic types, and so on, nested at least three levels deep. Ideally, I'd like to just design the data mo...

Persisting graph data (Java)

I have an application which utilizes graph (tree-like) custom structures. The structures are not real trees, but pretty much everything is connected together. The quantity of the data is also big (millions of nodes can exist). Tree-nodes can vary in type to make it more interesting (inheritance). I don't want to alter the data-structures...

Pure Python persistent key and value based container (a hash like interface) with large file system support?

I am looking for a (possibly) pure Python library for persistent hash table (btree or b+tree which would provide following features Large file support (possibly in terabytes) Fast enough and low memory footprint (looking for a descent balance between speed and memory) Low cost of management Reliability i.e. doesn't corrupt file once th...

BlackBerry Persistent store

I am developing an application in which I want to store many data entries using persistent store. the problem is whenever new entry is made it replaces the existing entry. here is my code please help me. import net.rim.device.api.ui.*; import net.rim.device.api.ui.component.*; import net.rim.device.api.ui.container.*; import net.rim.dev...

Hibernate Inheritance Mapping and Attribute Override

The system I'm working on has a domain object named Order which inherits from AbstractPersistentObject. Now I need to add another domain object named ExternalOrder which has some of the properties of Order but not all. I would like these two objects to be treated polimorphically in certain places. Hence I'm thinking of implementing inher...

Setting up relationships while importing core data?

I have an in memory managed object context called importMoc that I use to import records (e.g. employees). I have parsed a file and set up the employee objects in importMoc with one very important exception. The user confirms they want to process %d employees but I can't quite figure out how or when to set the "parent" relationship of th...

When to use EntityManager.find() vs EntityManager.getReference()

I have come across a situation (which I think is weird but is possibly quite normal) where I use the EntityManager.getReference(LObj.getClass(), LObj.getId()) to get a database entity and then pass the returned object to be persisted in another table. So basically the flow was like this: class TFacade{ createT(FObj, AObj) { T T...

what's the better strategy to store a set of MKAnnotations on file?

Is there a standardized way to persistence for MKAnnotations? ...

Db4O - Can I save a String?

I have the following code: Assert.IsTrue(Repository.FindAll<string>().Count() == 0); string newString = "New String"; Repository.Save(newString); Assert.IsTrue(Repository.FindAll<string>().Count() == 1); But it is failing. I suppose it has something to do with the fact that I'm saving a string. My Save() code is this: public v...

Keep website theme the same.. cookies?

I think I will need to use javascript to do this so I put it here on stack overflow. So, I have two themes for my website, the only difference is that one is a solid colour (background), the other a repeated image, so I didn't make separate css files for them. I have two links in the navigation bar that change it (with javascript). In th...

Does NHibernate interoperate with Hibernate? If not is there a framework out there for both Java and .NET?

Say you had: a database a bunch of .NET Windows GUI programs a bunch of Java web applications you could use Hibernate for the Java stuff and NHibernate for the .NET stuff - but would the two actually interoperate or would they be entirely different stacks? If not then is there a persistence framework out there that lets Java and .NE...

Linq to Entities: Mixed graph of Entities, EntityKeys, Attached, and New Objects

In my data model I have a fairly common division between my objects/tables/data: "Transactional" entities that represent the work that is being done by the system. These entities are created by the system and are only important in specific contexts. They are regularly created on the fly. (Aside: Is there a proper name for this type of ...

Avoid using a DB for storing small set of data on a Java EE App

I have a small JSF app and would like to keep some state on the server, without using a DB. It will just be a small string for every user so I don't see the point in deploying an RDMS for that. ...

Testing file based persistence

we have code that persists a file and I would like to check the content of the file during testing. I though that such scenario will be best implemented if I abstract the file persistence operation to the following interface: public interface IFilePersist { void Save(XXX, FileLocation); } In unit testing I will inject the mock that...

Rails backgroundRB plugin need to schedule it and queue to database for persistancy.

Hi, I'm trying to do the following: Run a Worker and a method within it every 15 minutes Have a log of the job last runtime, in the database table bdrd_job_queue. What I've done: I have a schedule every 15 minutes in my backgroundRB.yml file The method call has a persistent_job.finish! call, but it's not working, because the persi...

Persistence Using JPA Persistence.xml for Desktop App

I'm actually finishing a Desktop App That implements JPA for DB Communication. I Have a JPA Util class that does the following: private EntityManagerFactory emf = new EntityManagerFactory(); emf = Persistence.getEntityManagerFactory("default"); This "default" value is defined for my persistence.xml contained in the META-INF source fol...

Java - DAO Layer or Plugin

Hi, I work on the JBJF Project on SourceForge and we want to improve on the Database Access for this framework. Currently, it's semi-flexible, but the access is done at the Task level. We'd like to setup a simple Interface of some kind that's generic in nature and can host the database access to/from JBJF. Thus, Framework classes don...

ORM/Persistence layer Advice

Hi all I'm starting a new project and I'm looking around for either a very good ORM or for a non-SQL-based persistence layer. For this project, I really don't care on how the data is persisted, as long as it can be queried and stored with a reasonable speed and most importantly with simple queries. Concurrency should be handled seamlessl...

JDO, GAE: Load object group by child's key

I have owned one-to-many relationship between two objects: @PersistenceCapable(identityType = IdentityType.APPLICATION) public class AccessInfo { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private com.google.appengine.api.datastore.Key keyInternal; ... @Persistent private PollIn...

What's the best way to save data locally in a WPF Application?

I'm building some WPF application to manage my time. I'd like to save time spans for work time on project for a calendar day. So my question is what's the best choice on how to save the data? I figured I could use an XML file, an Access database file or maybe a property. I´d like to save the data locally, so no SQL Server action in thi...