Storage: Add resource version matching in unified storage API (#102417)

Add NotOlderThan support to getHistory

Add support for Exact

Add tests

Refactor tests

Add error test

Co-authored-by: Marco de Abreu <18629099+marcoabreu@users.noreply.github.com>
This commit is contained in:
Marco de Abreu
2025-03-19 16:16:48 +01:00
committed by GitHub
parent e5b6b7b370
commit ce350df79b
5 changed files with 169 additions and 19 deletions
@@ -18,4 +18,10 @@ WHERE 1 = 1
{{ if (gt .StartRV 0) }}
AND {{ .Ident "resource_version" }} < {{ .Arg .StartRV }}
{{ end }}
{{ if (gt .MinRV 0) }}
AND {{ .Ident "resource_version" }} >= {{ .Arg .MinRV }}
{{ end }}
{{ if (gt .ExactRV 0) }}
AND {{ .Ident "resource_version" }} = {{ .Arg .ExactRV }}
{{ end }}
ORDER BY resource_version DESC