From 5fc2b2c6956e040d5900a263bddcc14f81fa8d09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gon=C3=A7alo=20Heleno?= Date: Wed, 3 Apr 2024 11:42:09 +0200 Subject: [PATCH] feat: enable caching for index writes --- locals.tf | 7 +++++++ variables.tf | 11 +++++++++++ 2 files changed, 18 insertions(+) diff --git a/locals.tf b/locals.tf index 6f6e3f27..d40ccd0d 100644 --- a/locals.tf +++ b/locals.tf @@ -172,6 +172,13 @@ locals { limits = { for k, v in var.resources.memcached_index_queries.limits : k => v if v != null } } } + memcachedIndexWrites = { + enabled = true + resources = { + requests = { for k, v in var.resources.memcached_index_writes.requests : k => v if v != null } + limits = { for k, v in var.resources.memcached_index_writes.limits : k => v if v != null } + } + } queryScheduler = { enabled = true affinity = "" diff --git a/variables.tf b/variables.tf index 7957e925..97b2eec8 100644 --- a/variables.tf +++ b/variables.tf @@ -174,6 +174,17 @@ variable "resources" { }), {}) }), {}) + memcached_index_writes = optional(object({ + requests = optional(object({ + cpu = optional(string, "100m") + memory = optional(string, "256Mi") + }), {}) + limits = optional(object({ + cpu = optional(string) + memory = optional(string, "512Mi") + }), {}) + }), {}) + promtail = optional(object({ requests = optional(object({ cpu = optional(string, "100m")