Good point. This needs updating so that it is an integer field. Unless you think we should be storing the full issue number? We lose a bit of flexibility with this approach however.

I imagined an event would handle the issue number (issue pre-create event). There is the small possibility of a race condition, but we're talking within 100ms. We could attempt to re-fetch the issue number if creation fails because one already exists. The difficulty we will have is enforcing uniqueness on this value in the domain layer. We can't rely on MySQL to enforce it because we would need the key across two tables (project issue prefix and the issue number)