views:

465

answers:

3

I am currently working in a project with developers working on three sites. One of the sites is in Delhi, India while the other two are in Europe. The communication between the European offices and the office in Delhi has poor bandwidth and quite bad latency, and a CVS update from there often takes 5-10 minutes even though only a few files have changed.

Is there any good CVS proxies out there, or any neat way of keeping separate CVS servers in sync? Do you have any other tips on how the performance can be improved in this scenario?

Unfortunately, we will be stuck with CVS during the scope of this project, so switching to something completely different is not an option in the short-term.

+1  A: 

Why isn't switching an option?

I would highly recommend to switch to SVN or git instead. And that you do this conversion as soon as possible... like today :)

There are even svn tools/guides and git tools/guides out there that will do this CVS conversion for you.

I personally use and love SVN for my work, but based on your above description, it sounds like git might be the better option for you.

Brian R. Bondy
We will definitely switch! However, given the size of the organization (>200 people) and quite a lot of automatic tools and procedures relying on CVS I guess it will take some months before the change can be effective. We need some time to plan, and to convince the managers. =)
norheim.se
all the more reason to switch faster. >200 people's time are being wasted.
Brian R. Bondy
I was able to convert several very large project over in under a day, but my team is only ~20 people.
Brian R. Bondy
Actually, it is only the <10 Indian developers that are suffering from the bandwidth- and latency related issues. The developers in Europe have no performance issues (but would still definitely benefit from the features of SVN).
norheim.se
Perhaps you can convert just one project at a time. Even if you do not suffer from any issues of CVS, the difference from SVN is monumental. My only regret in switching from CVS to SVN is that I did not do it sooner. You will be a much more productive team. Much much more.
Brian R. Bondy
Thanks a lot. These arguments will definitely help me hurrying up the eventual transition.
norheim.se
+1  A: 

Here is what I have done a long time ago in similar circumstances when bandwidth and unreliable networks were an issue:

  • Make a copy of the repository and install it in the remote location. You know have CVS1 and CVS2.
  • Lock one of the two copies (CVS1) by preventing commits. This is achieved by modifying 'commitinfo' in the CVSROOT module.
  • CVS1 can be used for updates only
  • CVS2 can be used for updates and commit

When you want to give access in commit to copy 1, proceed as follows:

  • Lock CVS2
  • Copy CVS2 to CVS1
  • Unlock CVS1

This sounds cumbersome, and it is if you do it manually, but it works. It requires a bit of discipline if you do it manually. May be timezones are on your side for once.

I wrote a tool to keep track of who had the commit token and to transfer repositories from one site to another automatically via rsync and SSH. It worked nicely for a couple of years. We never lost any data and it took about 5 minutes to transfer the token from one location to another.

The transfer tool was written in perl and it took me about two weeks to develop it, working on it full time.

I know that a long time ago FreeBSD developers used CVSup but I never used that tool myself.

David Segonds
A: 

Please, please, please do not use CVS. CVS is essentially a toy, which will not protect you from versioning problems. It's better than nothing, but not better than RCS or any other version control system that keeps track of changesets over your whole repository.

SVN is an alternative that kind of feels similar to CVS.

There are numerous distributed version control systems designed for your task. Google "distributed version control" and use one of those.

Marcin