persistence

Why does GetMachineStoreForAssembly() use different directories sometimes?

I've got an assembly in my framework, the purpose of which is to manage some data common to several applications that I am building. The assembly uses isolated storage to persist the data. The assembly itself happens to be a command-line .exe application and it can be executed directly as a tool to examine and make changes to the data....

GAE, change an class for a persistent object.

Hi. I have a web application with some data in its datastore. I have just finished another version of it, in which i changed one of the persistent classes. Basically, there is a class called "Node" (which represents a node in a hierarchy tree), that used to have it's author as a private CmsUser author; and now it stores its author ...

Hibernate - Saving Entities - Update Table - Not based on Primary Key

Pseudo code to get to the point: @Entity Person { @Id Integer id; String SSN; String name; } Use case for repository, or service: personRepository.save(new Person(ssn:"123456", name:"jeff")): id is unique and autoincremented primary key SSN is unique and is the identifier of a person name is just a string and could be ...

Java Persistence frameworks

I am in need of some further information. I am developing a small application which will be interacting with a PHP web application. The media server which we are incorporating with is extensible in Java. I need very little access to the database inside the plugin which we are developing, I only need to view rows in about 10% of the ta...

Is checking whether a DataMapper (or other ORM) model is persisted a code smell?

I've found myself starting to leverage checking persistence to get my models to 'work'. It seems convenient and correct to include a persistence check. On the other hand, it feels a little shady, as if I was being overly cautious or breaking the ORM abstraction in a small way. An example might be: class Shipment include DataMapper:Re...

How to store (and read) large arrays/maps/whatever in Java?

Can anyone help me with following problem? I need to permanently save what I today have in arrays, to later use the data for calculations. I explain an example below. 1, I generate a long[][] which is far too big for my computers RAM. It is generated one row after the other. 2, I calculate something from my long[][] and save the result...

Google App Engine: Storing unowned many to many relationship

I have two objects a user and a role which I make persistant using JDO and googles app engine. The two datatypes are related to each other as unowned many to many relationship. I tried to model that much as in the gae-tutorial desribed as sets holding the key of the corresponding object. By the time I create my objects, those keys are nu...

Set entityManager components.xml seam weblogic

Hi guys, I develop an application with Seam 2.2.0 on weblogic 10.3 In my components.xml, when I set my entityManager, I do this: <persistence:managed-persistence-context name="entityManager" auto-create="true" persistence-unit-jndi-name="OSSPortailDataSource" /> My DataSource is configured like this on weblogic: JNDI name: ...

Ideas for Persistence Approach

I'm looking for some ideas to best persist an object over multiple page requests without the use of session variables, cookies, context cache, view state or a session database. I have a web form (ASPX) that will contain several user controls that will act as "pages", and these controls will be displayed in a one-at-a-time-manner: <uc1:...

Static vs Dynamic Properties of SNMPv3

I'm looking into implementing SNMPv3 as a requirement for monitoring a specific device on the network. As it is now, our project consists of a number of different Java classes that represent each device to be monitored on the network. Within each of these classes are a number of device-specific attributes that are needed in properly mon...

Persist List<int> through App Shutdowns

Short Version I have a list of ints that I need to figure out how to persist through Application Shutdown. Not forever but, you get the idea, I can't have the list disappear before it is dealt with. The method for dealing with it will remove entry's in the list. What are my options? XML? Background We have a WinForm app that uses ...

Making data persistent in android

In my application,there are some application specific settings, which should be available to me , next time when my application starts up. In other words i want the data to be available across the sessions of an application cycle. Can this be achieved without using database(sqlite). ...

Class not refreshing on 2nd url call

Hi there, I have a web page with a link to a url eg./customer/showitem?id=7, which displays details of a specific customer in a child-window using method showitem() in class customer. The method may set the value of a customer class attribute that controls an alert which is displayed when the page is loaded (eg. self.onloadalert="Warni...

Storing a hash in memory

Hi, I have 1 GB file of tables with data separated by columns. I have parsed it and stored in hash. Later on I am using this hash for my further work. But during developing my code each time I compile for testing the " parsing and storing into hash" is executed and which makes my program slow. Is there any way where I can store it so ...

How do I implement object-persistence not involving loading to memory?

I have a Graph object (this is in Perl) for which I compute its transitive closure (i.e. for solving the all-pairs shortest paths problem). From this object, I am interested in computing: Shortest path from any vertices u -> v. Distance matrix for all vertices. General reachability questions. General graph features (density, etc). T...

Trouble deploying EJB application to JBoss when implementing persistence

I'm trying to implement EJB persistence, but I'm having trouble deploying my application to JBoss. In my application I have the session bean TeamMgr, which looks like this: package ejb; import javax.ejb.Local; import javax.ejb.Remote; import javax.ejb.Stateless; import javax.persistence.EntityManager; import javax.persistence.Persisten...

Approach for decoupling persistence from domain objects?

I understand that it's better if objects are not responsible for their own persistence (makes testing the objects easier, plus separation of responsibilities), but then what object should handle persistence of domain objects, and what should the persistence API look like at a high-level? ...

Are there databases that bases durability on redundancy and not on persistent storage?

Sorry that the title isn't exactly obvious, but I couldn't word it better. We are right now using a conventional DB (oracle) as our job queue, and these "jobs" are consumed by some number of nodes (machines). So the DB server gets hit by these nodes, and we have to pay a lot for the software and hardware for this database server. N...

Method to Prevent Workflow Foundation 3.5 from persisting an executing workflow

Is there a way to prevent a WCF 3.5 workflow from being persisted? I have an issue where some items in the workflow cannot be serialized so I need to block persistence. Is there a way do this in .NET 3.5? ...

Grails problem persisting data in join tables for many-to-many relationships

I am having problems persisting domain objects where I have a many-to-many relationship with a join table class A{ String name static hasMany = [bs:B] } class B{ String surname static belongsTo=A static hasMany=[as:A] } A a = new A(name:'Test') B b = new B(surname:'user') a.addToBs(b) a.save(flush:true) Then what I would expec...