Why not create an additional custom reader (or readers)? See: the "ext" reader for an example. Also, the ext reader is where I put all of my customer-specific data, I don't touch seed-initial or seed.

There's nothing special about seed-initial or seed except that they are explicitly referenced to in the stock ant targets.

-Joe

On Aug 25, 2009, at 11:13 AM, Bob Morley wrote:


Background:
There are a number of data loaders in Ofbiz including "seed" and
"seed-initial". We use "seed-initial" as part of the database creation which is applied to the data once one time only. We use "seed" to ensure that standard entities are inserted/updated each time Ofbiz starts (or for
us as part of each customer migration).

The implication of this is that "seed-initial" will be standard entities that are loaded, but we do not want to seed them each time (often because
the user in Ofbiz may modify these entities).

Requirement:
We have situations where we have entities that need to be seeded as
"seed-initial" but they are added after the fact and need to be applied to customer deployments. Here is a theoretical example, I put a ProductStore in my "seed-initial" and a customer provisions a deployment and gets seeded with that store. Later on we decide that we should seed two stores for all our customers so we create a second store in "seed-initial". The trouble is that we can not execute seed-initial again, and it does not make sense to put this second store in "seed" (because we do not want it to be updated on
a future seed).

Potential Solution:
We considered the idea of making "seed-initial" strictly INSERT (not UPSERT as it is now) but we are leaning towards adding a "keyword" to the seed
entities that allows that entity to "insert-only".  The benefit of the
second approach, is that we can can keep things like the product store
"contextually close" to other seeded data preventing the split between
"seed" and "seed-initial".

Looking for some thoughts on this. Perhaps there is another way to get "insert-only" type entities to be seeded that I have not found or perhaps
there exists some configuration for each data loader.
--
View this message in context: 
http://www.nabble.com/Handling-one-time-seed-data-tp25136333p25136333.html
Sent from the OFBiz - Dev mailing list archive at Nabble.com.

Reply via email to