karafka-web 0.8.1 → 0.9.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/.github/workflows/ci.yml +5 -16
- data/CHANGELOG.md +47 -0
- data/Gemfile.lock +33 -35
- data/LICENSE +3 -3
- data/bin/rspecs +1 -1
- data/config/locales/pro_errors.yml +11 -0
- data/config/locales/slogans.yml +62 -0
- data/docker-compose.yml +1 -1
- data/karafka-web.gemspec +4 -2
- data/lib/karafka/web/app.rb +1 -1
- data/lib/karafka/web/config.rb +19 -0
- data/lib/karafka/web/contracts/config.rb +6 -0
- data/lib/karafka/web/installer.rb +4 -1
- data/lib/karafka/web/management/actions/create_topics.rb +21 -0
- data/lib/karafka/web/management/actions/delete_topics.rb +1 -0
- data/lib/karafka/web/management/actions/enable.rb +11 -5
- data/lib/karafka/web/management/migrations/0_base.rb +1 -1
- data/lib/karafka/web/pro/commanding/commands/base.rb +33 -0
- data/lib/karafka/web/pro/commanding/commands/probe.rb +41 -0
- data/lib/karafka/web/pro/commanding/commands/quiet.rb +31 -0
- data/lib/karafka/web/pro/commanding/commands/stop.rb +31 -0
- data/lib/karafka/web/pro/commanding/config.rb +57 -0
- data/lib/karafka/web/pro/commanding/contracts/config.rb +60 -0
- data/lib/karafka/web/pro/commanding/dispatcher.rb +93 -0
- data/lib/karafka/web/pro/commanding/listener.rb +97 -0
- data/lib/karafka/web/pro/commanding/manager.rb +98 -0
- data/lib/karafka/web/pro/commanding/matcher.rb +50 -0
- data/lib/karafka/web/pro/commanding.rb +40 -0
- data/lib/karafka/web/pro/loader.rb +40 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/app.rb +103 -22
- data/lib/karafka/web/{ui/pro/controllers/cluster.rb → pro/ui/controllers/base_controller.rb} +4 -5
- data/lib/karafka/web/pro/ui/controllers/cluster_controller.rb +54 -0
- data/lib/karafka/web/pro/ui/controllers/commanding_controller.rb +118 -0
- data/lib/karafka/web/pro/ui/controllers/commands_controller.rb +96 -0
- data/lib/karafka/web/{ui/pro/controllers/consumers.rb → pro/ui/controllers/consumers_controller.rb} +31 -4
- data/lib/karafka/web/{ui/pro/controllers/dashboard.rb → pro/ui/controllers/dashboard_controller.rb} +5 -3
- data/lib/karafka/web/pro/ui/controllers/dlq_controller.rb +60 -0
- data/lib/karafka/web/{ui/pro/controllers/errors.rb → pro/ui/controllers/errors_controller.rb} +5 -7
- data/lib/karafka/web/{ui/pro/controllers/explorer.rb → pro/ui/controllers/explorer_controller.rb} +24 -19
- data/lib/karafka/web/{ui/pro/controllers/health.rb → pro/ui/controllers/health_controller.rb} +16 -3
- data/lib/karafka/web/{ui/pro/controllers/jobs.rb → pro/ui/controllers/jobs_controller.rb} +4 -4
- data/lib/karafka/web/{ui/pro/controllers/messages.rb → pro/ui/controllers/messages_controller.rb} +8 -6
- data/lib/karafka/web/{ui/pro/controllers/routing.rb → pro/ui/controllers/routing_controller.rb} +6 -22
- data/lib/karafka/web/{ui/pro/controllers/status.rb → pro/ui/controllers/status_controller.rb} +3 -3
- data/lib/karafka/web/pro/ui/controllers/topics_controller.rb +99 -0
- data/lib/karafka/web/pro/ui/lib/patterns_detector.rb +50 -0
- data/lib/karafka/web/pro/ui/views/cluster/_breadcrumbs.erb +29 -0
- data/lib/karafka/web/pro/ui/views/cluster/_broker.erb +13 -0
- data/lib/karafka/web/pro/ui/views/cluster/_config.erb +13 -0
- data/lib/karafka/web/pro/ui/views/cluster/_tabs.erb +27 -0
- data/lib/karafka/web/pro/ui/views/cluster/brokers.erb +27 -0
- data/lib/karafka/web/pro/ui/views/cluster/index.erb +27 -0
- data/lib/karafka/web/pro/ui/views/cluster/show.erb +27 -0
- data/lib/karafka/web/pro/ui/views/commands/_backtrace.erb +20 -0
- data/lib/karafka/web/pro/ui/views/commands/_breadcrumbs.erb +21 -0
- data/lib/karafka/web/pro/ui/views/commands/_command.erb +60 -0
- data/lib/karafka/web/pro/ui/views/commands/_command_details.erb +11 -0
- data/lib/karafka/web/pro/ui/views/commands/_details.erb +26 -0
- data/lib/karafka/web/pro/ui/views/commands/_empty.erb +3 -0
- data/lib/karafka/web/pro/ui/views/commands/_incompatible_schema.erb +14 -0
- data/lib/karafka/web/pro/ui/views/commands/_metadata.erb +50 -0
- data/lib/karafka/web/pro/ui/views/commands/_table.erb +23 -0
- data/lib/karafka/web/pro/ui/views/commands/index.erb +17 -0
- data/lib/karafka/web/pro/ui/views/commands/show.erb +38 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/_breadcrumbs.erb +20 -4
- data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/_consumer.erb +2 -21
- data/lib/karafka/web/pro/ui/views/consumers/_consumer_controls.erb +78 -0
- data/lib/karafka/web/pro/ui/views/consumers/_consumer_performance.erb +59 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/_counters.erb +7 -5
- data/lib/karafka/web/pro/ui/views/consumers/_tabs.erb +35 -0
- data/lib/karafka/web/pro/ui/views/consumers/consumer/_commands.erb +32 -0
- data/lib/karafka/web/pro/ui/views/consumers/consumer/_no_jobs.erb +7 -0
- data/lib/karafka/web/pro/ui/views/consumers/consumer/_no_subscriptions.erb +7 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/consumer/_subscription_group.erb +20 -9
- data/lib/karafka/web/pro/ui/views/consumers/consumer/_title.erb +5 -0
- data/lib/karafka/web/pro/ui/views/consumers/controls.erb +67 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/details.erb +6 -1
- data/lib/karafka/web/pro/ui/views/consumers/index.erb +39 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/pending_jobs.erb +15 -7
- data/lib/karafka/web/pro/ui/views/consumers/performance.erb +52 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/running_jobs.erb +15 -7
- data/lib/karafka/web/pro/ui/views/consumers/subscriptions.erb +28 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/dashboard/index.erb +10 -10
- data/lib/karafka/web/pro/ui/views/dlq/_no_topics.erb +7 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/dlq/index.erb +1 -1
- data/lib/karafka/web/{ui/pro → pro/ui}/views/errors/_error.erb +2 -6
- data/lib/karafka/web/pro/ui/views/errors/_table.erb +23 -0
- data/lib/karafka/web/pro/ui/views/explorer/_failed_deserialization.erb +4 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/_message.erb +7 -1
- data/lib/karafka/web/pro/ui/views/explorer/_no_topics.erb +5 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/index.erb +1 -6
- data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/message/_metadata.erb +33 -9
- data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/message/_payload.erb +4 -4
- data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/message/_payload_actions.erb +1 -1
- data/lib/karafka/web/pro/ui/views/explorer/messages/_headers.erb +33 -0
- data/lib/karafka/web/pro/ui/views/explorer/messages/_key.erb +20 -0
- data/lib/karafka/web/pro/ui/views/explorer/partition/_cleaned.erb +5 -0
- data/lib/karafka/web/pro/ui/views/explorer/partition/_empty.erb +5 -0
- data/lib/karafka/web/pro/ui/views/explorer/partition/_messages.erb +21 -0
- data/lib/karafka/web/pro/ui/views/explorer/topic/_empty.erb +5 -0
- data/lib/karafka/web/pro/ui/views/explorer/topic/_limited.erb +10 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/health/_breadcrumbs.erb +8 -0
- data/lib/karafka/web/pro/ui/views/health/_no_data.erb +7 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/health/_partition.erb +1 -1
- data/lib/karafka/web/{ui/pro → pro/ui}/views/health/_partition_lags.erb +6 -3
- data/lib/karafka/web/{ui/pro → pro/ui}/views/health/_tabs.erb +11 -1
- data/lib/karafka/web/{ui/pro → pro/ui}/views/health/changes.erb +15 -10
- data/lib/karafka/web/pro/ui/views/health/cluster_lags.erb +54 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/health/lags.erb +16 -10
- data/lib/karafka/web/{ui/pro → pro/ui}/views/health/offsets.erb +17 -14
- data/lib/karafka/web/{ui/pro → pro/ui}/views/health/overview.erb +23 -9
- data/lib/karafka/web/{ui/pro → pro/ui}/views/jobs/_job.erb +1 -1
- data/lib/karafka/web/pro/ui/views/jobs/_no_jobs.erb +7 -0
- data/lib/karafka/web/{ui/pro → pro/ui}/views/jobs/pending.erb +12 -8
- data/lib/karafka/web/{ui/pro → pro/ui}/views/jobs/running.erb +12 -8
- data/lib/karafka/web/{ui/pro → pro/ui}/views/routing/_consumer_group.erb +2 -2
- data/lib/karafka/web/{ui/pro → pro/ui}/views/routing/index.erb +1 -1
- data/lib/karafka/web/{ui/pro → pro/ui}/views/routing/show.erb +1 -1
- data/lib/karafka/web/{ui/pro → pro/ui}/views/shared/_navigation.erb +14 -0
- data/lib/karafka/web/pro/ui/views/topics/_breadcrumbs.erb +37 -0
- data/lib/karafka/web/pro/ui/views/topics/_partition.erb +16 -0
- data/lib/karafka/web/pro/ui/views/topics/_tabs.erb +37 -0
- data/lib/karafka/web/pro/ui/views/topics/_topic.erb +12 -0
- data/lib/karafka/web/pro/ui/views/topics/config.erb +29 -0
- data/lib/karafka/web/pro/ui/views/topics/distribution/_badges.erb +7 -0
- data/lib/karafka/web/pro/ui/views/topics/distribution/_chart.erb +2 -0
- data/lib/karafka/web/pro/ui/views/topics/distribution/_empty_partitions.erb +1 -0
- data/lib/karafka/web/pro/ui/views/topics/distribution/_limited.erb +10 -0
- data/lib/karafka/web/pro/ui/views/topics/distribution/_partition.erb +10 -0
- data/lib/karafka/web/pro/ui/views/topics/distribution.erb +47 -0
- data/lib/karafka/web/pro/ui/views/topics/index.erb +16 -0
- data/lib/karafka/web/pro/ui/views/topics/replication.erb +28 -0
- data/lib/karafka/web/processing/consumers/aggregators/base.rb +1 -1
- data/lib/karafka/web/processing/consumers/aggregators/metrics.rb +1 -1
- data/lib/karafka/web/processing/consumers/aggregators/state.rb +4 -4
- data/lib/karafka/web/tracking/consumers/contracts/report.rb +1 -1
- data/lib/karafka/web/tracking/consumers/contracts/subscription_group.rb +1 -1
- data/lib/karafka/web/tracking/consumers/listeners/booting.rb +36 -0
- data/lib/karafka/web/tracking/consumers/listeners/errors.rb +2 -2
- data/lib/karafka/web/tracking/consumers/reporter.rb +3 -3
- data/lib/karafka/web/tracking/consumers/sampler.rb +10 -4
- data/lib/karafka/web/tracking/contracts/error.rb +1 -1
- data/lib/karafka/web/tracking/producers/listeners/booting.rb +26 -0
- data/lib/karafka/web/tracking/producers/listeners/errors.rb +2 -2
- data/lib/karafka/web/tracking/producers/reporter.rb +1 -1
- data/lib/karafka/web/tracking/producers/sampler.rb +1 -1
- data/lib/karafka/web/tracking/sampler.rb +3 -3
- data/lib/karafka/web/tracking/scheduler.rb +0 -5
- data/lib/karafka/web/ui/app.rb +13 -9
- data/lib/karafka/web/ui/base.rb +1 -0
- data/lib/karafka/web/ui/controllers/{base.rb → base_controller.rb} +15 -2
- data/lib/karafka/web/ui/controllers/{become_pro.rb → become_pro_controller.rb} +1 -1
- data/lib/karafka/web/ui/controllers/{cluster.rb → cluster_controller.rb} +4 -4
- data/lib/karafka/web/ui/controllers/{consumers.rb → consumers_controller.rb} +3 -3
- data/lib/karafka/web/ui/controllers/{dashboard.rb → dashboard_controller.rb} +1 -1
- data/lib/karafka/web/ui/controllers/{errors.rb → errors_controller.rb} +2 -2
- data/lib/karafka/web/ui/controllers/{jobs.rb → jobs_controller.rb} +5 -5
- data/lib/karafka/web/ui/controllers/{routing.rb → routing_controller.rb} +2 -2
- data/lib/karafka/web/ui/controllers/{status.rb → status_controller.rb} +1 -1
- data/lib/karafka/web/ui/helpers/alerts_helper.rb +23 -0
- data/lib/karafka/web/ui/helpers/application_helper.rb +55 -1
- data/lib/karafka/web/ui/lib/paginations/offset_based.rb +3 -4
- data/lib/karafka/web/ui/lib/safe_runner.rb +59 -0
- data/lib/karafka/web/ui/models/broker.rb +66 -0
- data/lib/karafka/web/ui/models/health.rb +28 -2
- data/lib/karafka/web/ui/models/message.rb +9 -3
- data/lib/karafka/web/ui/models/process.rb +19 -5
- data/lib/karafka/web/ui/models/processes.rb +2 -2
- data/lib/karafka/web/ui/models/topic.rb +78 -0
- data/lib/karafka/web/ui/public/javascripts/application.js +18 -1
- data/lib/karafka/web/ui/public/javascripts/charts/data_formatting_utility.js +71 -0
- data/lib/karafka/web/ui/public/javascripts/charts/dataset_state_manager.js +49 -0
- data/lib/karafka/web/ui/public/javascripts/charts/types/bar.js +123 -0
- data/lib/karafka/web/ui/public/javascripts/charts/types/line.js +143 -0
- data/lib/karafka/web/ui/public/javascripts/charts.js +10 -325
- data/lib/karafka/web/ui/public/javascripts/live_poll.js +5 -5
- data/lib/karafka/web/ui/public/javascripts/tabs_manager.js +57 -0
- data/lib/karafka/web/ui/public/stylesheets/application.css +7 -6
- data/lib/karafka/web/ui/views/cluster/_breadcrumbs.erb +3 -3
- data/lib/karafka/web/ui/views/cluster/_no_partitions.erb +1 -3
- data/lib/karafka/web/ui/views/cluster/_tabs.erb +3 -3
- data/lib/karafka/web/ui/views/cluster/brokers.erb +19 -19
- data/lib/karafka/web/ui/views/cluster/replication.erb +37 -0
- data/lib/karafka/web/ui/views/consumers/_assignments_badges.erb +24 -0
- data/lib/karafka/web/ui/views/consumers/_consumer.erb +2 -15
- data/lib/karafka/web/ui/views/consumers/_counters.erb +1 -1
- data/lib/karafka/web/ui/views/consumers/_summary.erb +5 -5
- data/lib/karafka/web/ui/views/consumers/index.erb +22 -20
- data/lib/karafka/web/ui/views/dashboard/index.erb +9 -9
- data/lib/karafka/web/ui/views/errors/_cleaned.erb +1 -3
- data/lib/karafka/web/ui/views/errors/_error.erb +2 -6
- data/lib/karafka/web/ui/views/errors/_no_errors.erb +1 -3
- data/lib/karafka/web/ui/views/errors/index.erb +22 -20
- data/lib/karafka/web/ui/views/jobs/_job.erb +4 -1
- data/lib/karafka/web/ui/views/jobs/_no_jobs.erb +1 -3
- data/lib/karafka/web/ui/views/jobs/pending.erb +4 -3
- data/lib/karafka/web/ui/views/jobs/running.erb +4 -3
- data/lib/karafka/web/ui/views/routing/_consumer_group.erb +2 -2
- data/lib/karafka/web/ui/views/routing/index.erb +1 -1
- data/lib/karafka/web/ui/views/routing/show.erb +1 -1
- data/lib/karafka/web/ui/views/shared/_become_pro.erb +3 -3
- data/lib/karafka/web/ui/views/shared/_header.erb +16 -10
- data/lib/karafka/web/ui/views/shared/_navigation.erb +17 -3
- data/lib/karafka/web/ui/views/shared/_not_a_message.erb +5 -0
- data/lib/karafka/web/ui/views/shared/alerts/_info.erb +3 -0
- data/lib/karafka/web/ui/views/shared/charts/_bar.erb +7 -0
- data/lib/karafka/web/ui/views/shared/{_chart.erb → charts/_line.erb} +1 -1
- data/lib/karafka/web/ui/views/shared/exceptions/not_found.erb +1 -1
- data/lib/karafka/web/ui/views/status/show.erb +1 -1
- data/lib/karafka/web/version.rb +1 -1
- data/lib/karafka/web.rb +19 -2
- data.tar.gz.sig +0 -0
- metadata +191 -120
- metadata.gz.sig +0 -0
- data/lib/karafka/web/ui/pro/controllers/dlq.rb +0 -43
- data/lib/karafka/web/ui/pro/views/consumers/consumer/_no_jobs.erb +0 -9
- data/lib/karafka/web/ui/pro/views/consumers/consumer/_no_subscriptions.erb +0 -9
- data/lib/karafka/web/ui/pro/views/consumers/index.erb +0 -36
- data/lib/karafka/web/ui/pro/views/consumers/subscriptions.erb +0 -23
- data/lib/karafka/web/ui/pro/views/dlq/_no_topics.erb +0 -9
- data/lib/karafka/web/ui/pro/views/errors/_table.erb +0 -21
- data/lib/karafka/web/ui/pro/views/explorer/_failed_deserialization.erb +0 -4
- data/lib/karafka/web/ui/pro/views/explorer/_no_topics.erb +0 -7
- data/lib/karafka/web/ui/pro/views/explorer/messages/_headers.erb +0 -15
- data/lib/karafka/web/ui/pro/views/explorer/messages/_key.erb +0 -12
- data/lib/karafka/web/ui/pro/views/explorer/partition/_cleaned.erb +0 -3
- data/lib/karafka/web/ui/pro/views/explorer/partition/_empty.erb +0 -3
- data/lib/karafka/web/ui/pro/views/explorer/partition/_messages.erb +0 -19
- data/lib/karafka/web/ui/pro/views/explorer/topic/_empty.erb +0 -3
- data/lib/karafka/web/ui/pro/views/explorer/topic/_limited.erb +0 -4
- data/lib/karafka/web/ui/pro/views/health/_no_data.erb +0 -9
- data/lib/karafka/web/ui/pro/views/jobs/_no_jobs.erb +0 -9
- data/lib/karafka/web/ui/public/javascripts/tabs.js +0 -59
- data/lib/karafka/web/ui/views/cluster/topics.erb +0 -35
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/consumer/_consumer_group.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/consumer/_job.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/consumer/_metrics.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/consumer/_partition.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/consumer/_stopped.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/consumers/consumer/_tabs.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/dlq/_breadcrumbs.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/dlq/_topic.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/errors/_breadcrumbs.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/errors/_partition_option.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/errors/_title_with_select.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/errors/index.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/errors/partition.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/errors/show.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/_breadcrumbs.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/_filtered.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/_partition_option.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/_topic.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/message/_message_actions.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/messages/_detail.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/partition/_details.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/partition.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/show.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/topic/_details.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/explorer/topic.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/health/_consumer_group_header.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/health/_partition_offset.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/health/_partition_times.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/routing/_detail.erb +0 -0
- /data/lib/karafka/web/{ui/pro → pro/ui}/views/routing/_topic.erb +0 -0
- /data/lib/karafka/web/ui/public/javascripts/{bootstrap.min.js → libs/bootstrap.min.js} +0 -0
- /data/lib/karafka/web/ui/public/javascripts/{chart.min.js → libs/chart.min.js} +0 -0
- /data/lib/karafka/web/ui/public/javascripts/{datepicker.js → libs/datepicker.js} +0 -0
- /data/lib/karafka/web/ui/public/javascripts/{highlight.min.js → libs/highlight.min.js} +0 -0
- /data/lib/karafka/web/ui/public/javascripts/{timeago.min.js → libs/timeago.min.js} +0 -0
- /data/lib/karafka/web/ui/public/stylesheets/{bootstrap.min.css → libs/bootstrap.min.css} +0 -0
- /data/lib/karafka/web/ui/public/stylesheets/{datepicker.min.css → libs/datepicker.min.css} +0 -0
- /data/lib/karafka/web/ui/public/stylesheets/{highlight.min.css → libs/highlight.min.css} +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bb0a26726917ff55929bb34bf81e4a0a7b6f1e5db0e6c34fe11b85c2601cd9df
|
4
|
+
data.tar.gz: 20664c3ce3931cc4c770af78fe1ced92690cf5dd8f58bf0f24b7a05ecb05982a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b566ebc2f5c500e31fe4b20106fdf9adb022f89079109cd3131c6dd7950dbddedbbea1c389764c9e5c197074073da606aec9b3029303877e5b68123447bbf28b
|
7
|
+
data.tar.gz: 341b8acc29d5cd21c93d84227b86b4674390c50e3f43920837d5b3caaa286676cace4ea35d66c67349c04431733162a8720340ab2c297898a9a7548d5cc937df
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/.github/workflows/ci.yml
CHANGED
@@ -26,7 +26,6 @@ jobs:
|
|
26
26
|
- '3.2'
|
27
27
|
- '3.1'
|
28
28
|
- '3.0'
|
29
|
-
- '2.7'
|
30
29
|
include:
|
31
30
|
- ruby: '3.3'
|
32
31
|
coverage: 'true'
|
@@ -35,9 +34,9 @@ jobs:
|
|
35
34
|
- name: Install package dependencies
|
36
35
|
run: "[ -e $APT_DEPS ] || sudo apt-get install -y --no-install-recommends $APT_DEPS"
|
37
36
|
|
38
|
-
- name: Start Kafka with docker
|
37
|
+
- name: Start Kafka with docker compose
|
39
38
|
run: |
|
40
|
-
docker
|
39
|
+
docker compose up -d || (sleep 5 && docker compose up -d)
|
41
40
|
|
42
41
|
- name: Set up Ruby
|
43
42
|
uses: ruby/setup-ruby@v1
|
@@ -48,25 +47,15 @@ jobs:
|
|
48
47
|
|
49
48
|
- name: Install latest bundler
|
50
49
|
run: |
|
51
|
-
|
52
|
-
|
53
|
-
gem update --system 3.4.22 --no-document
|
54
|
-
else
|
55
|
-
gem install bundler --no-document
|
56
|
-
gem update --system --no-document
|
57
|
-
fi
|
50
|
+
gem install bundler --no-document
|
51
|
+
gem update --system --no-document
|
58
52
|
|
59
53
|
bundle config set without 'tools benchmarks docs'
|
60
54
|
|
61
55
|
- name: Bundle install
|
62
56
|
run: |
|
63
57
|
bundle config set without development
|
64
|
-
|
65
|
-
if [[ "$(ruby -v | awk '{print $2}')" == 2.7.8* ]]; then
|
66
|
-
BUNDLER_VERSION=2.4.22 bundle install --jobs 4 --retry 3
|
67
|
-
else
|
68
|
-
bundle install --jobs 4 --retry 3
|
69
|
-
fi
|
58
|
+
bundle install --jobs 4 --retry 3
|
70
59
|
|
71
60
|
- name: Wait for Kafka
|
72
61
|
run: |
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,52 @@
|
|
1
1
|
# Karafka Web changelog
|
2
2
|
|
3
|
+
## 0.9.0 (Unreleased)
|
4
|
+
- **[Breaking]** Drop Ruby `2.7` support.
|
5
|
+
- **[Feature]** Provide ability to stop and quiet running consumers (Pro).
|
6
|
+
- **[Feature]** Provide ability to probe (get backtraces) of any running consumer (Pro).
|
7
|
+
- **[Feature]** Provide cluster lags in Health (Pro).
|
8
|
+
- **[Feature]** Provide ability to inspect cluster nodes configuration (Pro).
|
9
|
+
- **[Feature]** Provide ability to inspect cluster topics configuration (Pro).
|
10
|
+
- **[Feature]** Provide messages distribution graph statistics for topics (Pro).
|
11
|
+
- [Enhancement] Provide first offset in the OSS jobs tab.
|
12
|
+
- [Enhancement] Support failover for custom deserialization of headers and key in the explorer (Pro).
|
13
|
+
- [Enhancement] Support failover for custom deserialization of headers and key in the explorer (Pro).
|
14
|
+
- [Enhancement] Limit length of `key` presented in the list view of the explorer.
|
15
|
+
- [Enhancement] Improve responsiveness on big screens by increasing max width.
|
16
|
+
- [Enhancement] Auto-qualify topics with dlq/dead_letter case insensitive name components to DLQ view.
|
17
|
+
- [Enhancement] Make tables responsive.
|
18
|
+
- [Enhancement] Provide page titles for ease of navigation.
|
19
|
+
- [Change] Rename Cluster => Topics to Cluster => Replication to better align with what is shows.
|
20
|
+
- [Change] Make support messages more entertaining.
|
21
|
+
- [Refactor] Normalize what is process name and process id.
|
22
|
+
- [Refactor] Create one `pro/` namespace for all Web related sub-modules.
|
23
|
+
- [Refactor] Extract alerts into a common component.
|
24
|
+
- [Refactor] Generalize charts generation.
|
25
|
+
- [Fix] Fix invalid return when paginating with offsets.
|
26
|
+
- [Fix] Improve responsiveness of summary in the consumers view for lower resolutions.
|
27
|
+
- [Fix] Align pages titles format.
|
28
|
+
- [Fix] Fix missing link from lag counter to Health.
|
29
|
+
- [Fix] Fix a case where on mobile charts would not load correctly.
|
30
|
+
- [Fix] Fix cases where long consumer names would break UI.
|
31
|
+
- [Fix] Explorer deserializer wrongly selected for pattern matched topics.
|
32
|
+
- [Fix] Fix 404 error page invalid recommendation of `install` instead of `migrate`.
|
33
|
+
- [Fix] Fix dangling `console.log`.
|
34
|
+
- [Fix] Fix a case where consumer assignments would not be truncated on the consumers view.
|
35
|
+
|
36
|
+
### Upgrade Notes
|
37
|
+
|
38
|
+
This is a **major** release that brings many things to the table.
|
39
|
+
|
40
|
+
This version of the Karafka Web UI should be upgraded together with Karafka. All upgrade documentation for Karafka and Web UI `0.9` can be found [here](https://karafka.io/docs/Upgrades-2.4/).
|
41
|
+
|
42
|
+
## 0.8.2 (2024-02-16)
|
43
|
+
- [Enhancement] Defer scheduler background thread creation until needed allowing for forks.
|
44
|
+
- [Enhancement] Tag forks with fork indication + ppid reference when operating in swarm.
|
45
|
+
- [Fix] Fix issue where Health tabs would not be visible when no data reported.
|
46
|
+
- [Fix] Stopped processes subscriptions lacks indicator of no groups.
|
47
|
+
- [Fix] Terminated process state not supported in the web ui.
|
48
|
+
- [Fix] Rebalance reason can be empty on a SG when no network.
|
49
|
+
|
3
50
|
## 0.8.1 (2024-02-01)
|
4
51
|
- [Enhancement] Introduce "Lags" health view.
|
5
52
|
- [Enhancement] Remove "Stored Lag" and "Committed Offset" from Health Overview due to Lags Tab.
|
data/Gemfile.lock
CHANGED
@@ -1,17 +1,17 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
karafka-web (0.
|
4
|
+
karafka-web (0.9.0.rc1)
|
5
5
|
erubi (~> 1.4)
|
6
|
-
karafka (>= 2.
|
7
|
-
karafka-core (>= 2.
|
6
|
+
karafka (>= 2.4.0.beta1, < 2.5.0)
|
7
|
+
karafka-core (>= 2.4.0.rc1, < 2.5.0)
|
8
8
|
roda (~> 3.68, >= 3.69)
|
9
9
|
tilt (~> 2.0)
|
10
10
|
|
11
11
|
GEM
|
12
12
|
remote: https://rubygems.org/
|
13
13
|
specs:
|
14
|
-
activesupport (7.1.3)
|
14
|
+
activesupport (7.1.3.2)
|
15
15
|
base64
|
16
16
|
bigdecimal
|
17
17
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
@@ -22,56 +22,54 @@ GEM
|
|
22
22
|
mutex_m
|
23
23
|
tzinfo (~> 2.0)
|
24
24
|
base64 (0.2.0)
|
25
|
-
bigdecimal (3.1.
|
25
|
+
bigdecimal (3.1.7)
|
26
26
|
byebug (11.1.3)
|
27
27
|
concurrent-ruby (1.2.3)
|
28
28
|
connection_pool (2.4.1)
|
29
|
-
diff-lcs (1.5.
|
29
|
+
diff-lcs (1.5.1)
|
30
30
|
docile (1.4.0)
|
31
|
-
drb (2.2.
|
32
|
-
ruby2_keywords
|
31
|
+
drb (2.2.1)
|
33
32
|
erubi (1.12.0)
|
34
|
-
factory_bot (6.4.
|
33
|
+
factory_bot (6.4.6)
|
35
34
|
activesupport (>= 5.0.0)
|
36
35
|
ffi (1.16.3)
|
37
|
-
i18n (1.14.
|
36
|
+
i18n (1.14.4)
|
38
37
|
concurrent-ruby (~> 1.0)
|
39
|
-
karafka (2.
|
40
|
-
karafka-core (>= 2.
|
41
|
-
waterdrop (>= 2.
|
38
|
+
karafka (2.4.0.beta1)
|
39
|
+
karafka-core (>= 2.4.0.rc1, < 2.5.0)
|
40
|
+
waterdrop (>= 2.7.0.rc1, < 3.0.0)
|
42
41
|
zeitwerk (~> 2.3)
|
43
|
-
karafka-core (2.
|
44
|
-
karafka-rdkafka (>= 0.
|
45
|
-
karafka-rdkafka (0.
|
42
|
+
karafka-core (2.4.0.rc1)
|
43
|
+
karafka-rdkafka (>= 0.15.0.rc1, < 0.16.0)
|
44
|
+
karafka-rdkafka (0.15.0.rc1)
|
46
45
|
ffi (~> 1.15)
|
47
46
|
mini_portile2 (~> 2.6)
|
48
47
|
rake (> 12)
|
49
48
|
mini_portile2 (2.8.5)
|
50
|
-
minitest (5.
|
49
|
+
minitest (5.22.3)
|
51
50
|
mutex_m (0.2.0)
|
52
|
-
rack (3.0.
|
51
|
+
rack (3.0.10)
|
53
52
|
rack-test (2.1.0)
|
54
53
|
rack (>= 1.3)
|
55
54
|
rackup (0.2.3)
|
56
55
|
rack (>= 3.0.0.beta1)
|
57
56
|
webrick
|
58
57
|
rake (13.1.0)
|
59
|
-
roda (3.
|
58
|
+
roda (3.78.0)
|
60
59
|
rack
|
61
|
-
rspec (3.
|
62
|
-
rspec-core (~> 3.
|
63
|
-
rspec-expectations (~> 3.
|
64
|
-
rspec-mocks (~> 3.
|
65
|
-
rspec-core (3.
|
66
|
-
rspec-support (~> 3.
|
67
|
-
rspec-expectations (3.
|
60
|
+
rspec (3.13.0)
|
61
|
+
rspec-core (~> 3.13.0)
|
62
|
+
rspec-expectations (~> 3.13.0)
|
63
|
+
rspec-mocks (~> 3.13.0)
|
64
|
+
rspec-core (3.13.0)
|
65
|
+
rspec-support (~> 3.13.0)
|
66
|
+
rspec-expectations (3.13.0)
|
68
67
|
diff-lcs (>= 1.2.0, < 2.0)
|
69
|
-
rspec-support (~> 3.
|
70
|
-
rspec-mocks (3.
|
68
|
+
rspec-support (~> 3.13.0)
|
69
|
+
rspec-mocks (3.13.0)
|
71
70
|
diff-lcs (>= 1.2.0, < 2.0)
|
72
|
-
rspec-support (~> 3.
|
73
|
-
rspec-support (3.
|
74
|
-
ruby2_keywords (0.0.5)
|
71
|
+
rspec-support (~> 3.13.0)
|
72
|
+
rspec-support (3.13.1)
|
75
73
|
simplecov (0.22.0)
|
76
74
|
docile (~> 1.1)
|
77
75
|
simplecov-html (~> 0.11)
|
@@ -81,11 +79,11 @@ GEM
|
|
81
79
|
tilt (2.3.0)
|
82
80
|
tzinfo (2.0.6)
|
83
81
|
concurrent-ruby (~> 1.0)
|
84
|
-
waterdrop (2.
|
85
|
-
karafka-core (>= 2.
|
82
|
+
waterdrop (2.7.0.rc1)
|
83
|
+
karafka-core (>= 2.4.0.rc1, < 3.0.0)
|
86
84
|
zeitwerk (~> 2.3)
|
87
85
|
webrick (1.8.1)
|
88
|
-
zeitwerk (2.6.
|
86
|
+
zeitwerk (2.6.13)
|
89
87
|
|
90
88
|
PLATFORMS
|
91
89
|
ruby
|
@@ -101,4 +99,4 @@ DEPENDENCIES
|
|
101
99
|
simplecov
|
102
100
|
|
103
101
|
BUNDLED WITH
|
104
|
-
2.5.
|
102
|
+
2.5.7
|
data/LICENSE
CHANGED
@@ -4,14 +4,14 @@ Karafka Web is part of Karafka and it is an Open Source project licensed under t
|
|
4
4
|
the LGPLv3 license. Please see <https://github.com/karafka/karafka/blob/master/LGPL>
|
5
5
|
for license text.
|
6
6
|
|
7
|
-
Karafka
|
7
|
+
Karafka and Karafka Web have also commercial-friendly license, commercial support and commercial components.
|
8
8
|
|
9
|
-
All of the commercial components are present in the lib/karafka/pro and lib/karafka/web/
|
9
|
+
All of the commercial components are present in the lib/karafka/pro and lib/karafka/web/pro
|
10
10
|
directory of this repository and their usage requires commercial license agreement.
|
11
11
|
|
12
12
|
By sending a pull request to the pro components, you are agreeing to transfer the copyright of your
|
13
13
|
code to Maciej Mensfeld.
|
14
14
|
|
15
|
-
You can find the commercial license in LICENSE-COMM.
|
15
|
+
You can find the commercial license in LICENSE-COMM <https://github.com/karafka/karafka/blob/master/LICENSE-COMM>.
|
16
16
|
|
17
17
|
Please see https://karafka.io for purchasing options.
|
data/bin/rspecs
CHANGED
@@ -0,0 +1,11 @@
|
|
1
|
+
en:
|
2
|
+
validations:
|
3
|
+
config:
|
4
|
+
missing: needs to be present
|
5
|
+
|
6
|
+
commanding.active_format: needs to be either true or false
|
7
|
+
commanding.consumer_group_format: 'needs to be a string with a Kafka accepted format'
|
8
|
+
commanding.max_wait_time_format: needs to be an integer bigger than 0
|
9
|
+
commanding.pause_timeout_format: needs to be an integer bigger than 0
|
10
|
+
key_must_be_a_symbol: All keys under the kafka settings scope need to be symbols
|
11
|
+
commanding.kafka_format: needs to be a filled hash
|
@@ -0,0 +1,62 @@
|
|
1
|
+
en:
|
2
|
+
slogans:
|
3
|
+
- "Unlock the full potential of Karafka with our Pro plan – Your support fuels innovation!"
|
4
|
+
- "Elevate your Karafka experience! Go Pro and access exclusive features today."
|
5
|
+
- "Support Karafka's future developments by upgrading to Pro. Together, we can achieve more!"
|
6
|
+
- "Maximize your productivity with Karafka Pro. Upgrade today for a seamless experience."
|
7
|
+
- "Be a part of something bigger. Your Pro subscription helps me innovate continuously."
|
8
|
+
- "Unlock premium features and dedicated support by upgrading to Karafka Pro."
|
9
|
+
- "Experience the best of Karafka with Pro: More features, more power."
|
10
|
+
- "Karafka Pro awaits with open arms. Upgrade now for a richer development experience."
|
11
|
+
- "Lead, innovate, and excel with Karafka Pro. Upgrade today to unlock your potential."
|
12
|
+
- "Your projects deserve the best. Upgrade to Karafka Pro for unmatched features."
|
13
|
+
- "Speed up your development timeline with Karafka's Pro advanced tools. Upgrade for efficiency!"
|
14
|
+
- "Get more done quickly with Karafka's Pro exclusive features. Upgrade to accelerate."
|
15
|
+
- "Fast-forward your projects with Karafka Pro. Efficiency is just an upgrade away."
|
16
|
+
- "Elevate your coding speed and project quality with Karafka Pro. Time to upgrade!"
|
17
|
+
- "Karafka Pro: Because your time is invaluable. Upgrade for a seamless, speedy workflow."
|
18
|
+
- "Your Pro upgrade powers my innovation - support Karafka's growth and OSS commitment."
|
19
|
+
- "Go Pro and become a pillar of the Karafka ecosystem. Support development, support OSS."
|
20
|
+
- "By choosing Pro, you're fueling our ability to enhance and expand the Karafka ecosystem."
|
21
|
+
- "Support us in shaping the future of Karafka. Your Pro subscription invests in OSS excellence."
|
22
|
+
- "Your support through Pro enables me to innovate and give back to the OSS community."
|
23
|
+
- "Enhance your impact on the OSS world. Upgrade to Karafka Pro and support our ecosystem."
|
24
|
+
- "Every Pro subscriber helps us invest more in Karafka and the broader OSS community."
|
25
|
+
- "Upgrade to Pro: Fuel Karafka's innovation and our dedication to OSS progress."
|
26
|
+
- "Your Pro subscription helps me reinvest in Karafka and contribute more to OSS."
|
27
|
+
- "Leverage Delayed Topics in Karafka Pro for precise message processing timing."
|
28
|
+
- "Automatically manage message lifecycles with the Expiring Messages feature in Karafka Pro."
|
29
|
+
- "Control consumption pace wisely with Rate Limiting, available in Karafka Pro."
|
30
|
+
- "Quickly access data with the Iterator API, a unique Karafka Pro feature."
|
31
|
+
- "Enhance throughput with Multiplexing, enabling parallel processing in Karafka Pro."
|
32
|
+
- "Need to process data faster? Explore Karafka Pro for parallel processing enhancements."
|
33
|
+
- "Struggling with data integrity? Karafka's Pro transaction features ensure reliability."
|
34
|
+
- "Want more control over message timing? Delayed Topics in Karafka Pro make scheduling easy."
|
35
|
+
- "Need to automate regular tasks? Periodic Jobs in Karafka Pro have got you covered."
|
36
|
+
- "Worried about message overload? Karafka's Pro Expiring Messages keep your queues clean."
|
37
|
+
- "Want to filter messages efficiently? Filtering API in Pro makes it simple."
|
38
|
+
- "Concerned about memory during batch operations? Cleaner API in Karafka Pro is the answer."
|
39
|
+
- "Need to increase processing speed? Karafka's Pro Multiplexing feature boosts throughput."
|
40
|
+
- "Looking for better message management? Enhanced Dead Letter Queue in Karafka Pro is key."
|
41
|
+
- "Concerned about Karafka licensing? Karafka Pro offers a commercial-friendly option."
|
42
|
+
- "Need coupled message operations? Transactions in Karafka Pro enhance data integrity."
|
43
|
+
- "Are you Concerned about managing large data flows? Virtual Partitions in Karafka Pro simplify data processing, offering unparalleled efficiency and scalability."
|
44
|
+
- "Looking for flexible scheduling solutions? Karafka's Pro Periodic Jobs feature allows for precise task timing and execution, enhancing your application's performance and reliability."
|
45
|
+
- "Need advanced routing capabilities? Routing Patterns in Karafka Pro provide dynamic message routing, improving your system's adaptability and efficiency."
|
46
|
+
- "Are you Seeking to control your workload? With Rate Limiting in Karafka Pro, you can manage and balance your system's load effectively, ensuring optimal performance under any conditions."
|
47
|
+
- "Need quick data access methods? The Iterator API in Karafka Pro provides efficient data retrieval methods."
|
48
|
+
- "Want more nuanced error handling? Discover Granular Backoffs in Karafka Pro, allowing for detailed control over retry mechanisms and error recovery processes."
|
49
|
+
- "Need a boost in data processing speed? Multiplexing in Karafka Pro enables parallel processing, significantly increasing throughput and reducing processing times."
|
50
|
+
- "Need advanced monitoring and management? Karafka Pro goes beyond basic features, offering comprehensive tools for detailed insight and control over your Kafka ecosystem."
|
51
|
+
- "Let's Build the Future of Karafka Together: Your Pro support brings next-gen features to life."
|
52
|
+
- "Karafka Pro: A Partnership for Progress. Your subscription drives our development."
|
53
|
+
- "With Karafka Pro, you're not just upgrading, you're fueling the future of efficient coding."
|
54
|
+
- "Dare to Support, Dare to Grow: Karafka Pro is your contribution to a boundary-pushing ecosystem."
|
55
|
+
- "Ivest in Karafka Pro to ensure ongoing enhancements and a dynamic, evolving platform."
|
56
|
+
- "Advance with us. Your Karafka Pro subscription is a stepping stone for collective innovation."
|
57
|
+
- "Together, we can push boundaries. Support Karafka's growth by upgrading to Pro."
|
58
|
+
- "Karafka's continuous improvement is powered by our community. Consider going Pro to contribute."
|
59
|
+
- "By choosing Karafka Pro, you're investing in a more robust, feature-rich future for your projects."
|
60
|
+
- "Help me help you. Karafka's future developments depend on your support through Pro."
|
61
|
+
- "Supporting Karafka through Pro enables me to continually enhance its features and support your business better."
|
62
|
+
- "Your upgrade to Karafka Pro directly fuels our capacity to innovate and improve. Let's grow together."
|
data/docker-compose.yml
CHANGED
data/karafka-web.gemspec
CHANGED
@@ -17,13 +17,15 @@ Gem::Specification.new do |spec|
|
|
17
17
|
spec.licenses = %w[LGPL-3.0 Commercial]
|
18
18
|
|
19
19
|
spec.add_dependency 'erubi', '~> 1.4'
|
20
|
-
spec.add_dependency 'karafka', '>= 2.
|
21
|
-
spec.add_dependency 'karafka-core', '>= 2.
|
20
|
+
spec.add_dependency 'karafka', '>= 2.4.0.beta1', '< 2.5.0'
|
21
|
+
spec.add_dependency 'karafka-core', '>= 2.4.0.rc1', '< 2.5.0'
|
22
22
|
spec.add_dependency 'roda', '~> 3.68', '>= 3.69'
|
23
23
|
spec.add_dependency 'tilt', '~> 2.0'
|
24
24
|
|
25
25
|
spec.add_development_dependency 'rackup', '~> 0.2'
|
26
26
|
|
27
|
+
spec.required_ruby_version = '>= 3.0.0'
|
28
|
+
|
27
29
|
if $PROGRAM_NAME.end_with?('gem')
|
28
30
|
spec.signing_key = File.expand_path('~/.ssh/gem-private_key.pem')
|
29
31
|
end
|
data/lib/karafka/web/app.rb
CHANGED
data/lib/karafka/web/config.rb
CHANGED
@@ -41,6 +41,12 @@ module Karafka
|
|
41
41
|
|
42
42
|
# Topic for storing consumers historical metrics info
|
43
43
|
setting :metrics, default: 'karafka_consumers_metrics'
|
44
|
+
|
45
|
+
# Topic for storing commands and their results
|
46
|
+
# This is used only in Pro, however we do setup it in OSS in case of upgrade so the
|
47
|
+
# transition from one to another is smooth. Otherwise upgrade would require changes
|
48
|
+
# to topics (migration) which may be more complex
|
49
|
+
setting :commands, default: 'karafka_consumers_commands'
|
44
50
|
end
|
45
51
|
end
|
46
52
|
|
@@ -69,6 +75,7 @@ module Karafka
|
|
69
75
|
|
70
76
|
# Listeners needed for the Web UI to track consumer related changes
|
71
77
|
setting :listeners, default: [
|
78
|
+
Tracking::Consumers::Listeners::Booting.new,
|
72
79
|
Tracking::Consumers::Listeners::Status.new,
|
73
80
|
Tracking::Consumers::Listeners::Errors.new,
|
74
81
|
Tracking::Consumers::Listeners::Connections.new,
|
@@ -88,6 +95,7 @@ module Karafka
|
|
88
95
|
|
89
96
|
# Listeners needed for the Web UI to track producers related stuff
|
90
97
|
setting :listeners, default: [
|
98
|
+
Tracking::Producers::Listeners::Booting.new,
|
91
99
|
Tracking::Producers::Listeners::Errors.new
|
92
100
|
]
|
93
101
|
end
|
@@ -136,6 +144,11 @@ module Karafka
|
|
136
144
|
# Should we display internal topics of Kafka. The once starting with `__`
|
137
145
|
# By default we do not display them as they are not usable from regular users perspective
|
138
146
|
setting :internal_topics, default: false
|
147
|
+
|
148
|
+
# Should we display cluster lags only for active topics
|
149
|
+
# Useful for multi-app setups where the web-ui routing does not match the routing setup
|
150
|
+
# of micro-services and topics are not active but lags reporting should be in use
|
151
|
+
setting :active_topics_cluster_lags_only, default: true
|
139
152
|
end
|
140
153
|
|
141
154
|
# How many elements should we display on pages that support pagination
|
@@ -151,6 +164,12 @@ module Karafka
|
|
151
164
|
# are dealing with
|
152
165
|
setting :visibility_filter, default: Ui::Models::VisibilityFilter.new
|
153
166
|
|
167
|
+
# Consider any topic matching those names as a DLQ topic for the DLQ view
|
168
|
+
# Web UI uses auto DLQ discovery based on routing but this may not be fully operable when
|
169
|
+
# using a multi-app setup. This config allows to add extra topics if needed without having
|
170
|
+
# to explicitly define routing
|
171
|
+
setting :dlq_patterns, default: [/(dlq)|(dead_letter)/i]
|
172
|
+
|
154
173
|
# Specific kafka settings that are tuned to operate within the Web UI interface.
|
155
174
|
#
|
156
175
|
# Please do not change them unless you know what you are doing as their misconfiguration
|
@@ -58,9 +58,15 @@ module Karafka
|
|
58
58
|
required(:cache) { |val| !val.nil? }
|
59
59
|
required(:per_page) { |val| val.is_a?(Integer) && val >= 1 && val <= 100 }
|
60
60
|
|
61
|
+
required(:dlq_patterns) do |val|
|
62
|
+
val.is_a?(Array) &&
|
63
|
+
val.all? { |attr| attr.is_a?(String) || attr.is_a?(Regexp) }
|
64
|
+
end
|
65
|
+
|
61
66
|
nested(:visibility) do
|
62
67
|
required(:filter) { |val| !val.nil? }
|
63
68
|
required(:internal_topics) { |val| [true, false].include?(val) }
|
69
|
+
required(:active_topics_cluster_lags_only) { |val| [true, false].include?(val) }
|
64
70
|
end
|
65
71
|
end
|
66
72
|
end
|
@@ -12,6 +12,7 @@ module Karafka
|
|
12
12
|
#
|
13
13
|
# @param replication_factor [Integer] replication factor we want to use (1 by default)
|
14
14
|
def install(replication_factor: 1)
|
15
|
+
enable!
|
15
16
|
puts
|
16
17
|
puts 'Installing Karafka Web UI...'
|
17
18
|
puts
|
@@ -21,7 +22,6 @@ module Karafka
|
|
21
22
|
puts
|
22
23
|
Management::Actions::CreateTopics.new.call(replication_factor)
|
23
24
|
wait_for_topics
|
24
|
-
enable!
|
25
25
|
Management::Actions::CreateInitialStates.new.call
|
26
26
|
puts
|
27
27
|
puts 'Running data migrations...'
|
@@ -36,6 +36,7 @@ module Karafka
|
|
36
36
|
#
|
37
37
|
# @param replication_factor [Integer] replication factor we want to use (1 by default)
|
38
38
|
def migrate(replication_factor: 1)
|
39
|
+
enable!
|
39
40
|
puts
|
40
41
|
puts 'Creating necessary topics and populating state data...'
|
41
42
|
puts
|
@@ -53,6 +54,7 @@ module Karafka
|
|
53
54
|
# Removes all the Karafka topics and creates them again with the same replication factor
|
54
55
|
# @param replication_factor [Integer] replication factor we want to use (1 by default)
|
55
56
|
def reset(replication_factor: 1)
|
57
|
+
enable!
|
56
58
|
puts
|
57
59
|
puts 'Resetting Karafka Web UI...'
|
58
60
|
puts
|
@@ -71,6 +73,7 @@ module Karafka
|
|
71
73
|
|
72
74
|
# Removes all the Karafka Web topics and cleans after itself.
|
73
75
|
def uninstall
|
76
|
+
enable!
|
74
77
|
puts
|
75
78
|
puts 'Uninstalling Karafka Web UI...'
|
76
79
|
puts
|
@@ -20,6 +20,7 @@ module Karafka
|
|
20
20
|
consumers_states_topic = ::Karafka::Web.config.topics.consumers.states
|
21
21
|
consumers_metrics_topic = ::Karafka::Web.config.topics.consumers.metrics
|
22
22
|
consumers_reports_topic = ::Karafka::Web.config.topics.consumers.reports
|
23
|
+
consumers_commands_topic = ::Karafka::Web.config.topics.consumers.commands
|
23
24
|
errors_topic = ::Karafka::Web.config.topics.errors
|
24
25
|
|
25
26
|
if existing_topics_names.include?(errors_topic)
|
@@ -88,6 +89,26 @@ module Karafka
|
|
88
89
|
created(consumers_metrics_topic)
|
89
90
|
end
|
90
91
|
|
92
|
+
if existing_topics_names.include?(consumers_commands_topic)
|
93
|
+
exists(consumers_commands_topic)
|
94
|
+
else
|
95
|
+
creating(consumers_commands_topic)
|
96
|
+
# Commands are suppose to live short and be used for controlling processes and some
|
97
|
+
# debug. Their data can be removed safely fast.
|
98
|
+
::Karafka::Admin.create_topic(
|
99
|
+
consumers_commands_topic,
|
100
|
+
1,
|
101
|
+
replication_factor,
|
102
|
+
{
|
103
|
+
'cleanup.policy': 'delete',
|
104
|
+
'retention.ms': 7 * 24 * 60 * 60 * 1_000, # 7 days
|
105
|
+
'segment.ms': 12 * 60 * 60 * 1_000, # 24h
|
106
|
+
'segment.bytes': 104_857_600 # 100MB
|
107
|
+
}
|
108
|
+
)
|
109
|
+
created(consumers_commands_topic)
|
110
|
+
end
|
111
|
+
|
91
112
|
# Create only if needed
|
92
113
|
if existing_topics_names.include?(consumers_states_topic)
|
93
114
|
exists(consumers_states_topic)
|
@@ -12,6 +12,7 @@ module Karafka
|
|
12
12
|
::Karafka::Web.config.topics.consumers.states,
|
13
13
|
::Karafka::Web.config.topics.consumers.reports,
|
14
14
|
::Karafka::Web.config.topics.consumers.metrics,
|
15
|
+
::Karafka::Web.config.topics.consumers.commands,
|
15
16
|
::Karafka::Web.config.topics.errors
|
16
17
|
].each do |topic_name|
|
17
18
|
if existing_topics_names.include?(topic_name.to_s)
|
@@ -37,7 +37,7 @@ module Karafka
|
|
37
37
|
# Enables all the needed routes
|
38
38
|
def extend_routing
|
39
39
|
::Karafka::App.routes.draw do
|
40
|
-
|
40
|
+
payload_deserializer = ::Karafka::Web::Deserializer.new
|
41
41
|
|
42
42
|
consumer_group ::Karafka::Web.config.processing.consumer_group do
|
43
43
|
# Topic we listen on to materialize the states
|
@@ -52,7 +52,7 @@ module Karafka
|
|
52
52
|
# This needs to be true in order not to reload the consumer in dev. This consumer
|
53
53
|
# should not be affected by the end user development process
|
54
54
|
consumer_persistence true
|
55
|
-
|
55
|
+
deserializers(payload: payload_deserializer)
|
56
56
|
manual_offset_management true
|
57
57
|
# Start from the most recent data, do not materialize historical states
|
58
58
|
# This prevents us from dealing with cases, where client id would be changed and
|
@@ -66,19 +66,25 @@ module Karafka
|
|
66
66
|
topic ::Karafka::Web.config.topics.consumers.states do
|
67
67
|
config(active: false)
|
68
68
|
active false
|
69
|
-
|
69
|
+
deserializers(payload: payload_deserializer)
|
70
70
|
end
|
71
71
|
|
72
72
|
topic ::Karafka::Web.config.topics.consumers.metrics do
|
73
73
|
config(active: false)
|
74
74
|
active false
|
75
|
-
|
75
|
+
deserializers(payload: payload_deserializer)
|
76
|
+
end
|
77
|
+
|
78
|
+
topic ::Karafka::Web.config.topics.consumers.commands do
|
79
|
+
config(active: false)
|
80
|
+
active false
|
81
|
+
deserializers(payload: payload_deserializer)
|
76
82
|
end
|
77
83
|
|
78
84
|
topic ::Karafka::Web.config.topics.errors do
|
79
85
|
config(active: false)
|
80
86
|
active false
|
81
|
-
|
87
|
+
deserializers(payload: payload_deserializer)
|
82
88
|
end
|
83
89
|
end
|
84
90
|
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# This Karafka component is a Pro component under a commercial license.
|
4
|
+
# This Karafka component is NOT licensed under LGPL.
|
5
|
+
#
|
6
|
+
# All of the commercial components are present in the lib/karafka/pro directory of this
|
7
|
+
# repository and their usage requires commercial license agreement.
|
8
|
+
#
|
9
|
+
# Karafka has also commercial-friendly license, commercial support and commercial components.
|
10
|
+
#
|
11
|
+
# By sending a pull request to the pro components, you are agreeing to transfer the copyright of
|
12
|
+
# your code to Maciej Mensfeld.
|
13
|
+
|
14
|
+
module Karafka
|
15
|
+
module Web
|
16
|
+
module Pro
|
17
|
+
module Commanding
|
18
|
+
# Namespace for commands the process can react to
|
19
|
+
module Commands
|
20
|
+
# Base for all the commands
|
21
|
+
class Base
|
22
|
+
private
|
23
|
+
|
24
|
+
# @return [String] current process id
|
25
|
+
def process_id
|
26
|
+
@process_id ||= ::Karafka::Web.config.tracking.consumers.sampler.process_id
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|