c/bmaas/bmdb: rework Work API into working form

The Work API within the BMDB library wasn't quite working for purely
BMDB-directed control loops. We fix that by turning Work into a
three-phase process of retrieval, side-effect causing work and
committing.

We also add a test that exercises this functionality alongside the Agent
tags and installation retrieval queries.

Change-Id: I43af0c02af034e402dadb3e3a1fd10e5a8fe680a
Reviewed-on: https://review.monogon.dev/c/monogon/+/998
Tested-by: Jenkins CI
Reviewed-by: Mateusz Zalega <mateusz@monogon.tech>
diff --git a/cloud/bmaas/bmdb/BUILD.bazel b/cloud/bmaas/bmdb/BUILD.bazel
index 882d73c..65a11c7 100644
--- a/cloud/bmaas/bmdb/BUILD.bazel
+++ b/cloud/bmaas/bmdb/BUILD.bazel
@@ -31,5 +31,6 @@
     deps = [
         "//cloud/bmaas/bmdb/model",
         "//cloud/lib/component",
+        "@com_github_google_uuid//:uuid",
     ],
 )