wood burning stoves 2.0*
The moose likes Java in General and the fly likes Logic for Version Controlling ?? 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 » Java » Java in General
Bookmark "Logic for Version Controlling ??" Watch "Logic for Version Controlling ??" New topic
Author

Logic for Version Controlling ??

samir ware
Ranch Hand

Joined: Jul 27, 2005
Posts: 192
Hi all ,
I am trying to develop an application where the version controlling is an integral part. I want to implement the logic for controlling the different versions of the file (same as in VSS,ClearCase,CVS) .
Can anybody please tell me the logic for the same . Is it possible that I could maintain a single physical file which reflect the multiple logical files . Any link any white paper will be appriciated.
Thanks and regards
Samir
Stan James
(instanceof Sidekick)
Ranch Hand

Joined: Jan 29, 2003
Posts: 8791
Any chance you could just use SubVersion and not tell anyone?

I retain all versions of pages and documents on my Wiki in a subfolder called "archive" and with a timestamp appended into the filename. Users can bring up a list of all archived versions, view, restore from archive, etc. Is that the kind of thing you need to do?


A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi
samir ware
Ranch Hand

Joined: Jul 27, 2005
Posts: 192
Thanks a lot Stan for your kind help ....But if we maintain the different versions of the same file...I mean the physical files on the disk ...Don't you think it will create an extra memory utilization as well as reduce the scalability ....Thats the last option I am thinking about ...
Only if we could use the same file which can replicate the different versions somehow....that could improve the performance....
Is there any way to do it ???
Gavin Tranter
Ranch Hand

Joined: Jan 01, 2007
Posts: 333
Hi, I am sure a web search of how the different source control systems work will give you some ideas.

If subversion is open source (I cant remember) looking at the souorce might give you some ideas, or you might be able to build subversion into your application.

I guess you really only have two choices, keep a copy of each version of the file/directory, I think clearCase works in this manner.
The other is to store the difference (delta) between the original file, and the first version of the file.

Although the file version is probably disakspace heavy it would be the easier of the two to implement, and harddisk space is very cheap.

I am sure a websearch for source control thoeries would work, also I would assume that content management systems work in about the same way, so that might add to your search terms.

Anyway just my thoughts on the subject.

G
Gabriel Claramunt
Ranch Hand

Joined: May 26, 2007
Posts: 375
Just a comment, ClearCase (and I guess most of versioning systems) stores delta for text file versions and the whole new version for binary files.


Gabriel
Software Surgeon
Stan James
(instanceof Sidekick)
Ranch Hand

Joined: Jan 29, 2003
Posts: 8791
Years ago PVCS was configurable to store the original plus deltas forwards, the latest plus deltas backwards, or all full files.

My Wiki has an ArchiveJanitor that retains at least x copies plus any number up to y days old and deletes the rest from the active disk. It zips everything and stores it at another location first. The Wiki ran for two or three years before I decided this was even needed - the "list all versions" function was getting a bit slow.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Logic for Version Controlling ??
 
Similar Threads
source code and new version entegration problem
As i am drawing sequence diagram for prepare itinerary...
why is the method not getting executed??
stateful session bean
File Upload Help needed