From 4d42dfccedb830871bb2833efd24f516810d0d16 Mon Sep 17 00:00:00 2001 From: Wojciech Trocki Date: Tue, 15 Mar 2022 15:55:52 +0000 Subject: [PATCH] fix: add data mock --- .../api-mock/src/handlers/kafka-manager.js | 30 +++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/packages/api-mock/src/handlers/kafka-manager.js b/packages/api-mock/src/handlers/kafka-manager.js index eb4e241d..240c5c34 100644 --- a/packages/api-mock/src/handlers/kafka-manager.js +++ b/packages/api-mock/src/handlers/kafka-manager.js @@ -182,6 +182,36 @@ function createKafkaHandlers(preSeed) { }); }, + getInstanceTypesByCloudProviderAndRegion: async (c, req, res) => { + res.status(200).json({ + "kind": "SupportedKafkaInstanceTypesList", + "page": "1", + "size": "1", + "total": "1", + "item": { + "value": { + "kind": "SupportedKafkaInstanceType", + "id": "eval", + "sizes": [ + { + "id": "x1", + "ingress_throughput_per_sec": "30Mi", + "egress_throughput_per_sec": "30Mi", + "total_max_connections": 3000, + "max_data_retention_size": "1000Gi", + "max_partitions": 1000, + "max_data_retention_period": "P14D", + "max_connection_attempts_per_sec": 100, + "quota_consumed": 1, + "quota_type": "rhosak", + "capacity_consumed": 1 + } + ] + } + } + }); + }, + // Handling auth notFound: async (c, req, res) => res.status(404).json({ err: "not found" }), unauthorizedHandler: async (c, req, res) =>