From 59108da9bc09f4de1879e01c87008acf70ab9f92 Mon Sep 17 00:00:00 2001 From: Yaara Date: Tue, 4 Jun 2024 17:36:39 +0100 Subject: [PATCH 1/2] added 2 apis for streams --- .../1/apis/api-5ead711f5759610001818678.json | 6 +-- ...-oas-13e832db947f4fd37ff4a86f453f8d8d.json | 2 +- ...-oas-566d32b4dd1241187b4fc25d01fbaa63.json | 22 +++++++++- ...-oas-b84fe1a04e5648927971c0557971565c.json | 2 +- .../policy-641c15dd0fffb800010197bf.json | 42 +++++++++---------- deployments/tyk/docker-compose.yml | 2 + 6 files changed, 48 insertions(+), 28 deletions(-) diff --git a/deployments/tyk/data/tyk-dashboard/1/apis/api-5ead711f5759610001818678.json b/deployments/tyk/data/tyk-dashboard/1/apis/api-5ead711f5759610001818678.json index 9009a44d..1393f225 100644 --- a/deployments/tyk/data/tyk-dashboard/1/apis/api-5ead711f5759610001818678.json +++ b/deployments/tyk/data/tyk-dashboard/1/apis/api-5ead711f5759610001818678.json @@ -303,13 +303,13 @@ "api_model": {}, "event_timeout": 60, "header_map": {}, - "id": "66599f26cf8bf50001c2852e", + "id": "665edf7b6fe5ee00019a40da", "method": "POST", "name": "Webhook Receiver Post", "org_id": "5e9d9544a1dcd60001d0ed20", "target_path": "http://localhost:8080/webhook-receiver/post", "template_path": "", - "webhook_id": "8870a92fb9f54f36b33347bf86e0b891" + "webhook_id": "8c057e6c754d4212a75c08f8cf1d95a3" } } ] @@ -394,7 +394,7 @@ "event_timeout": 60, "hook": { "api_model": {}, - "id": "66599f26cf8bf50001c2852e", + "id": "665edf7b6fe5ee00019a40da", "webhook_id": "", "org_id": "5e9d9544a1dcd60001d0ed20", "name": "Webhook Receiver Post", diff --git a/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-13e832db947f4fd37ff4a86f453f8d8d.json b/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-13e832db947f4fd37ff4a86f453f8d8d.json index 4b897f6f..881a6a45 100644 --- a/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-13e832db947f4fd37ff4a86f453f8d8d.json +++ b/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-13e832db947f4fd37ff4a86f453f8d8d.json @@ -13,7 +13,7 @@ ], "x-tyk-api-gateway": { "info": { - "dbId": "6659a069cf8bf50001c2853e", + "dbId": "665edf7e6fe5ee00019a40db", "id": "13e832db947f4fd37ff4a86f453f8d8d", "name": "Stream - http proxy with data append", "orgId": "5e9d9544a1dcd60001d0ed20", diff --git a/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-566d32b4dd1241187b4fc25d01fbaa63.json b/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-566d32b4dd1241187b4fc25d01fbaa63.json index 158f3f68..8670ba24 100644 --- a/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-566d32b4dd1241187b4fc25d01fbaa63.json +++ b/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-566d32b4dd1241187b4fc25d01fbaa63.json @@ -5,7 +5,18 @@ "version": "1.0.0" }, "openapi": "3.0.3", - "paths": {}, + "paths": { + "/": { + "get": { + "operationId": "get", + "responses": { + "200": { + "description": "" + } + } + } + } + }, "servers": [ { "url": "http://tyk-gateway.localhost:8080/stream-write-stdout/" @@ -13,7 +24,7 @@ ], "x-tyk-api-gateway": { "info": { - "dbId": "66599f31cf8bf50001c2852f", + "dbId": "665edf7e6fe5ee00019a40dc", "id": "566d32b4dd1241187b4fc25d01fbaa63", "name": "Stream - write to stdout", "orgId": "5e9d9544a1dcd60001d0ed20", @@ -29,6 +40,13 @@ "trafficLogs": { "enabled": true } + }, + "operations": { + "get": { + "allow": { + "enabled": true + } + } } }, "server": { diff --git a/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-b84fe1a04e5648927971c0557971565c.json b/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-b84fe1a04e5648927971c0557971565c.json index 000f4b34..0017cb45 100644 --- a/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-b84fe1a04e5648927971c0557971565c.json +++ b/deployments/tyk/data/tyk-dashboard/1/apis/api-oas-b84fe1a04e5648927971c0557971565c.json @@ -145,7 +145,7 @@ ], "x-tyk-api-gateway": { "info": { - "dbId": "66599f31cf8bf50001c28530", + "dbId": "665edf7e6fe5ee00019a40dd", "id": "b84fe1a04e5648927971c0557971565c", "name": "OAS HTTPbin", "orgId": "5e9d9544a1dcd60001d0ed20", diff --git a/deployments/tyk/data/tyk-dashboard/1/policies/policy-641c15dd0fffb800010197bf.json b/deployments/tyk/data/tyk-dashboard/1/policies/policy-641c15dd0fffb800010197bf.json index cef6da87..123a4de5 100644 --- a/deployments/tyk/data/tyk-dashboard/1/policies/policy-641c15dd0fffb800010197bf.json +++ b/deployments/tyk/data/tyk-dashboard/1/policies/policy-641c15dd0fffb800010197bf.json @@ -6,8 +6,8 @@ "state": "active", "access_rights_array": [ { - "api_name": "Rate Limit Path API 2", - "api_id": "c252af6eaf2e43ca5c89465af4f481c1", + "api_name": "Rate Limit Proxy API", + "api_id": "d1dfc6a927a046c54c0ed470f19757cc", "versions": [ "Default" ], @@ -15,24 +15,13 @@ "restricted_types": [], "allowed_types": [], "disable_introspection": false, - "limit": { - "rate": 3, - "per": 6, - "throttle_interval": -1, - "throttle_retry_limit": -1, - "max_query_depth": -1, - "quota_max": -1, - "quota_renews": 0, - "quota_remaining": 0, - "quota_renewal_rate": -1, - "set_by_policy": false - }, + "limit": null, "field_access_rights": [], "allowance_scope": "" }, { - "api_name": "Rate Limit Proxy API", - "api_id": "d1dfc6a927a046c54c0ed470f19757cc", + "api_name": "Rate Limit Path API 1", + "api_id": "d371b83b249845a2497ab9a947fd6210", "versions": [ "Default" ], @@ -40,13 +29,24 @@ "restricted_types": [], "allowed_types": [], "disable_introspection": false, - "limit": null, + "limit": { + "rate": 1, + "per": 5, + "throttle_interval": -1, + "throttle_retry_limit": -1, + "max_query_depth": -1, + "quota_max": -1, + "quota_renews": 0, + "quota_remaining": 0, + "quota_renewal_rate": -1, + "set_by_policy": false + }, "field_access_rights": [], "allowance_scope": "" }, { - "api_name": "Rate Limit Path API 1", - "api_id": "d371b83b249845a2497ab9a947fd6210", + "api_name": "Rate Limit Path API 2", + "api_id": "c252af6eaf2e43ca5c89465af4f481c1", "versions": [ "Default" ], @@ -55,8 +55,8 @@ "allowed_types": [], "disable_introspection": false, "limit": { - "rate": 1, - "per": 5, + "rate": 3, + "per": 6, "throttle_interval": -1, "throttle_retry_limit": -1, "max_query_depth": -1, diff --git a/deployments/tyk/docker-compose.yml b/deployments/tyk/docker-compose.yml index 4de41f83..0afd5c22 100755 --- a/deployments/tyk/docker-compose.yml +++ b/deployments/tyk/docker-compose.yml @@ -109,12 +109,14 @@ services: - tyk httpbin: image: kennethreitz/httpbin:latest + platform: linux/amd64 networks: tyk: aliases: - httpbin2 swagger-petstore: image: swaggerapi/petstore:1.0.5 + platform: linux/amd64 networks: - tyk environment: From 73b8c23a7bcc916f9ab48fa22040378de03bd2c0 Mon Sep 17 00:00:00 2001 From: David Garvey Date: Fri, 7 Jun 2024 10:17:45 +0200 Subject: [PATCH 2/2] improve message re PoC --- deployments/tyk/bootstrap.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/deployments/tyk/bootstrap.sh b/deployments/tyk/bootstrap.sh index f9404f4a..aaba20e0 100755 --- a/deployments/tyk/bootstrap.sh +++ b/deployments/tyk/bootstrap.sh @@ -428,6 +428,7 @@ bootstrap_progress # exit due to bugs in PoC echo "Exiting bootstrap early, due to issues with standard APIs not being accessible" +echo "This is a temporary workaround during PoC - other data is still imported, so you can log in to the dashboard as usual etc" exit 0 log_message "Checking Gateway - Anonymous API access"