Why version counter and not timestamps

flyway

Solution

Quite a few questions here. I'll do my best to answer them.

Flyway's versioning system is flexible. It doesn't care whether your version is called 1.0, 20120816115123 or 2012.8.16.11.51.23. You are therefore free to use timestamps if you wish.

Reserving a version number can be a simple as adding your name next to a number on a whiteboard, a sheet of paper or a wiki page.

Flyway will detect multiple migrations with the same version and report an error.

Out of order migration support is currently the #1 requested issue and will be included in the upcoming 1.8 release.

Problem

Why does Flyway use version numbers rather than timestamps? How is that supposed to work with larger and possibly distributed teams? Do I have to send and e-mail to all team members announcing that I am now reserving version number xy for me? What happens if two developers both use the same version number? What if a lower version number is checked into version control (and executed by the build server on the integration database) after another higher number has already been checked in? I am used to mybatis-migrations that is closely modeled after the migrations in rails (>=2.1) where timestamps are used instead of version numbers. Right now I think timestamps make a lot more sense: I don't have to worry about version numbers and out of order migrations are easily detected.

Original source