From 1a5f07176ae61eefb561f33b849020a3c5eca27c Mon Sep 17 00:00:00 2001 From: An Tran Date: Tue, 21 Jan 2025 15:38:56 +1000 Subject: [PATCH 1/3] [spec] disable flaky test --- spec/resty/concurrent/timer_pool_executor_spec.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/spec/resty/concurrent/timer_pool_executor_spec.lua b/spec/resty/concurrent/timer_pool_executor_spec.lua index f45694ebf..621e6a6da 100644 --- a/spec/resty/concurrent/timer_pool_executor_spec.lua +++ b/spec/resty/concurrent/timer_pool_executor_spec.lua @@ -6,7 +6,8 @@ local noop = function() end describe('TimerPoolExecutor', function() describe('worker garbage collection', function() - it('automatically checks in back old workers', function() + --- Flaky test so mark it for now + pending('automatically checks in back old workers', function() local pool = TimerPoolExecutor.new({ max_timers = 1 }) assert(pool:post(noop):wait(timeout)) @@ -15,7 +16,7 @@ describe('TimerPoolExecutor', function() assert(pool:post(noop):wait(timeout)) end) - it('puts back worker even when task crashes', function () + pending('puts back worker even when task crashes', function () local pool = TimerPoolExecutor.new({ max_timers = 1 }) assert(pool:post(error, 'message'):wait(timeout)) From d0c8e93c2476ca17030419f1d11e6eed9da5937a Mon Sep 17 00:00:00 2001 From: An Tran Date: Wed, 22 Jan 2025 18:44:18 +1000 Subject: [PATCH 2/3] [ci] Limit to two workers By default we run the prove task based on the number of available CPU cores. The nprocs test will return the number of available CPU cores in the docker executor VM, however the medium resource class only has access to 3 CPUs. So the prove task will always spawn more workers than the number of available CPU cores, which then causes the CPU to max out during the test and cause random errors. --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 5b3083456..56927191d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -230,6 +230,7 @@ jobs: JUNIT_OUTPUT_FILE: tmp/junit/prove/report.xml TEST_NGINX_ERROR_LOG: tmp/junit/prove/error.log HARNESS: TAP::Harness::JUnit + NPROC: 2 - report-codecov: suite: prove flags: -f 'luacov.report.*.out' From 4b0f64698bc402980b1ab81a9b5685bfbcd25aa4 Mon Sep 17 00:00:00 2001 From: An Tran Date: Wed, 22 Jan 2025 23:28:00 +1000 Subject: [PATCH 3/3] Fix invalid link --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c3841631a..7cec1733b 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ oc new-app -f https://raw.githubusercontent.com/3scale/apicast/master/openshift/ - Performance: it is fast because it's built on top of [NGINX](https://www.nginx.com/) and uses [LuaJIT](https://luajit.org/). - Scalability: APIcast is stateless, so it scales horizontally. - Request transformation: allows to modify the headers, the path and the arguments of a request. -- Rate-limit: can apply limits based on a header, [JWT](https://jwt.io/) claims, the IP of the request and many more. +- Rate-limit: can apply limits based on a header, [JWT](https://datatracker.ietf.org/doc/html/rfc7519) claims, the IP of the request and many more. - Modular and extensible: thanks to the APIcast [policies framework](doc/policies.md). - Monitoring with [Prometheus](https://prometheus.io/). - [NGINX instrumentation](https://github.com/open-telemetry/opentelemetry-cpp-contrib) using [OpenTelemetry](https://opentelemetry.io/). Works with [Jaeger](https://www.jaegertracing.io/).