From 0eec6cb8571fda57cd44ab411c68a69018e1c927 Mon Sep 17 00:00:00 2001 From: Bence Janos Toth Date: Thu, 19 Sep 2024 14:54:00 +0700 Subject: [PATCH] Pass along new polling_opts (#249) --- lib/prom_ex/plugins/oban.ex | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/prom_ex/plugins/oban.ex b/lib/prom_ex/plugins/oban.ex index 98e4ea8..78a64ed 100644 --- a/lib/prom_ex/plugins/oban.ex +++ b/lib/prom_ex/plugins/oban.ex @@ -97,6 +97,8 @@ if Code.ensure_loaded?(Oban) do oban_supervisors = get_oban_supervisors(opts) + polling_opts = Keyword.get(opts, :opts, []) + # Queue length details Polling.build( :oban_queue_poll_metrics, @@ -110,7 +112,8 @@ if Code.ensure_loaded?(Oban) do measurement: :count, tags: [:name, :queue, :state] ) - ] + ], + polling_opts ) end