From bd3ca21d780c039652ef030c38a3d7fb0cee59dc Mon Sep 17 00:00:00 2001 From: ale <ale@incal.net> Date: Mon, 1 Mar 2021 11:16:39 +0000 Subject: [PATCH] Use the correct cms_info data type for aux-db webapp resources --- backend/webappdb/webappdb.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/backend/webappdb/webappdb.go b/backend/webappdb/webappdb.go index 67784dee..5166982a 100644 --- a/backend/webappdb/webappdb.go +++ b/backend/webappdb/webappdb.go @@ -11,6 +11,9 @@ import ( auxpb "git.autistici.org/ai3/tools/aux-db/proto" ) +// Data type of the webapp-related resources in aux-db. +const auxDbWebappDataType = "cms_info" + // AuxWebappBackend looks up website information (cms_info data type) in // the aux-db service. type AuxWebappBackend struct { @@ -112,7 +115,7 @@ func (tx *wdbTX) lookup(ctx context.Context, resources []*as.Resource) { for _, r := range resources { // Create the lookup key for aux-db. auxKey := auxpb.Key{ - Type: "webapp", + Type: auxDbWebappDataType, Shard: r.Shard, ResourceID: r.ID.String(), } -- GitLab