Add uuidv7 support for to Gitlab::Utils gem

What does this MR do and why?

Add uuidv7 support for to Gitlab::Utils gem

Be used in langgraph integration

This fails some tests as ruby 3.2.x doesn't have it (what we use in dotcom) but 3.3.x introduced it. We shall have this for some time.

References

How to set up and validate locally

Specs in gems/gitlab-utils

bundle exec rake rubocop
bundle exec rake spec

In rails console bin/rails c run

> Gitlab::Utils.uuid_v7
=> "019904a6-2110-7eb2-b4e8-428d11b4e26c"

Compare to what a ruby 3.3.x gives

> SecureRandom.uuid_v7
=> "019904a6-705d-7a9f-b1ff-aad4615bced5"

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Alper Akgun

Merge request reports

Loading