I was wondering what the best practice is when reusing projects, in particular those stored in an Oracle database.
Let's say I have a project that works well, and want to use it as a basis to create a new one. Can I "clone" this to make sure that I have secured my working project, and can experiment using the second one?
If I simply copy the files on my hard drive I am afraid these will point to the same objects in the oracle database, so I would end up with conflicting changes...
can you please advise?
This quite a complex topic and really depends on what you are wanting to achieve.
Presumably if you are wanting to clone the project then you will want the clone to end up being different in some way to the original. But you are wanting to use the data tree and all the forms as a starting point for the new project. Does this describe your situation?
If so, then there is curently no automatic way to achieve this. I think you would need to create the data trees etc. in the new project manually. Once done forms can be transferred by copy and paste (the result depends on how closely the old and new data trees match up).
There is definitely scope for automating this to a large extent and it will be interesting to find out more about what you are wanting to do.
the idea is to use the project I already have as a starting point for a new one. One case where I would want to do this is,is when I have a project in production and I am working on a new version. I would like to make sure I don't "break" the one that is already in production while I work on it. This seems to me particularly important when the project is shared.
One could decide to set up different environments for development, test and production. That could be an alternative. I am not sure how I would then move a project that I have developed on one database to the other two. How would I do that?
Any of these would potentially be possible, though we have no automated tools to do so at present.
Proabaly the best approach is to have different environments (dev, test, prod) and write a tool that pushed the configuration from one to the other. We know of one customer who developed an in-house tool that does something similar to this and certainly something similar could be done.
A key thing to work out would be how the tool would need to operate. e.g. how would it do the update without loosing things like users own forms, lists, queries etc. It were just updating an existing form (or adding a new one) it would be pretty simple, but changes to the data trees etc. would be more complex to handle, though in principle it should be possible.
We'd also like to create some tools that can migrate one database to another, including the data (e.g. take an oracle database and generate a local database containing the same data. But again this is a pretty complex task!
Hi Anna, Hi Tim
There a re two scenarios which I foresee for the cloning:
1) Having a some sort of savepoints or versioning. If I have a working version i save it, and if I break something later, I can return to the served versions.
2) Using an existing project as a template to create new, independent one without copying the entities and ddata tree. This is likely a development tool and would not need to deal with user generated data (queies, hit list and alike)
For #1 I assume you are talking only about the IJC metadata definitions (data trees, forms etc) not the actual data in the non-IJC tables?
If so then its probably possible to do this, but its far from a complete solution, as many modifications to the IJC schema involve creating tables/columns etc in the database, so it quite likely that any backup would be incompatible with the current set of tables.
The only realy solution is it do a full backup, and we don't want IJC to become an Oracle backup client.This is really the job of the DBA.
For #2 this is clearly a need that IJC does need to fulfill. We do have it on our plans, but its a pretty complex task so will take some time.
I do have a similar problem. I want to use a data tree from another project for another project as a template, because otherwise I always have to attach several substance information fileds by hand which is really time consuming in case of creating about 300 or more projects. Is it possibble to copy a data tree to a new project?
Copying a data tree is not currently possible. Its not a simple as it sounds as there is all the underlying paraphernalia (entities, relationships, tables, columns....) that also need to be considered.
Howewever, we are working on technology to support this sort of thing, so we hope to be able to enable this at some stage.
If it was the same data tree that was wanting to be created every time it would be possible to create this automatically by writing a script.
Ok do you have a simple manual to create such a script?
We have some sample scripts in developers guide. The script can be put together from them. Please refer to Groovy scripts and Groovy scriptlets sections.
Unfortunately we do not have simple tutorial how to create that script. But it can be put together from examples. The schema is then hardcoded in the resulting sript => less flexible. It is convenient only when you want to create exactly the same schema repeatedly.