Skip to content

Conversation

@saurabhpimpalgaokar123
Copy link
Contributor

@saurabhpimpalgaokar123 saurabhpimpalgaokar123 commented Nov 13, 2025

PR Title 💥

Please title this PR with a summary of the change, along with the JIRA card number.

Suggested formats:

  1. Fixes/Refs #RHIROS-XXX - Title
  2. RHIROS-XXX Title

Feel free to remove this section from PR description once done.

Why do we need this change? 💭

Please include the context of this change here.

Documentation update? 📝

  • Yes
  • No

Security Checklist 🔒

Upon raising this PR please go through RedHatInsights/secure-coding-checklist

💂‍♂️ Checklist 🎯

  • Bugfix
  • New Feature
  • Refactor
  • Unittests Added
  • DRY code
  • Dependency Added
  • DB Migration Added

Additional 📣

Feel free to add any other relevant details such as links, notes, screenshots, here.

Summary by Sourcery

Allow dynamic selection of backend version by replacing KESSEL flags with a unified BACKEND_VERSION parameter and adapting pull request checks and deployment arguments accordingly

New Features:

  • Introduce BACKEND_VERSION environment variable to toggle between old and new backend

Enhancements:

  • Remove all KESSEL-related environment variables and Kafka topic ros.events from clowdapp configuration
  • Add BYPASS_UNLEASH parameter defaulting to false

CI:

  • Update pr_check.sh to set IQE marker expressions and IBUTSU source based on BACKEND_VERSION
  • Pass BACKEND_VERSION to deployment via EXTRA_DEPLOY_ARGS

@sourcery-ai
Copy link

sourcery-ai bot commented Nov 13, 2025

Reviewer's Guide

This PR refactors deployment configs by removing legacy KESSEL environment variables in favor of a unified BACKEND_VERSION parameter across all services, and enhances the PR check script to dynamically select IQE test markers and CI metadata based on the backend version.

Flow diagram for backend version selection in PR check script

flowchart TD
    Start(["Start PR check script"]) --> GetVersion["Read BACKEND_VERSION (default: 'old')"]
    GetVersion --> Decision{Is BACKEND_VERSION 'old', 'new', or other?}
    Decision -->|old| OldVars["Set IQE_MARKER_EXPRESSION='ros_smoke and (common or old_backend)'\nSet IBUTSU_SOURCE='ros-old-backend-pr'"]
    Decision -->|new| NewVars["Set IQE_MARKER_EXPRESSION='ros_smoke and (common or new_backend)'\nSet IBUTSU_SOURCE='ros-new-backend-pr'"]
    Decision -->|other| DefaultVars["Set IQE_MARKER_EXPRESSION='ros_smoke'\nSet IBUTSU_SOURCE='ros-backend-pr'"]
    OldVars --> End(["Continue CI/CD pipeline"])
    NewVars --> End
    DefaultVars --> End
Loading

File-Level Changes

Change Details Files
Replaced KESSEL environment variables with BACKEND_VERSION parameter in deployment manifests
  • Removed multiple KESSEL_* environment entries from containers
  • Added BACKEND_VERSION environment variable to all service specs
  • Updated parameter definitions: removed KESSEL_* defaults and added BACKEND_VERSION and BYPASS_UNLEASH
  • Removed obsolete ros.events Kafka topic entry
clowdapp.yaml
Extended pr_check.sh to support backend version selection
  • Introduced BACKEND_VERSION default and branching logic
  • Dynamic IQE_MARKER_EXPRESSION and IBUTSU_SOURCE based on version
  • Removed static IQE_MARKER_EXPRESSION and added EXTRA_DEPLOY_ARGS
pr_check.sh

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey there - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Copy link
Contributor

@upadhyeammit upadhyeammit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At the same time, are we also wanting to handle a trigger for both pipelines? or we can just use two triggers and that should be good as well

pr_check.sh Outdated
# NEW: Dual backend testing logic based on job name
echo "JOB_NAME: $JOB_NAME"

if [[ "$JOB_NAME" == *"old-backend"* ]]; then
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will need change based on ros-backend-v1-pr-tests

pr_check.sh Outdated

if [[ "$JOB_NAME" == *"old-backend"* ]]; then
# Old backend testing configuration
export ROS_NEW_BACKEND_FLAG_ENABLED="false"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

which flag is this? and where its getting used?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://gitlab.cee.redhat.com/insights-qe/iqe-ros-plugin/-/merge_requests/413
This flag is used in iqe.
Can you please check this pr.

pr_check.sh Outdated
# Old backend testing configuration
export ROS_NEW_BACKEND_FLAG_ENABLED="false"
export IQE_MARKER_EXPRESSION="ros_smoke and (common or old_backend)"
export IBUTSU_SOURCE="ros-old-backend-pr"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is it possible to make this in sync with name ros-backend-v1-pr-tests

pr_check.sh Outdated
echo " Configured for OLD backend testing"
echo " - Unleash flag will be set to: FALSE"
echo " - Test markers: ros_smoke and (common or old_backend)"
elif [[ "$JOB_NAME" == *"new-backend"* ]]; then
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make this in sync with ros-backend-v2-pr-tests

pr_check.sh Outdated
echo " - Test markers: ros_smoke and (common or old_backend)"
elif [[ "$JOB_NAME" == *"new-backend"* ]]; then
# New backend testing configuration
export ROS_NEW_BACKEND_FLAG_ENABLED="true"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same, where this is getting used?

pr_check.sh Outdated
# New backend testing configuration
export ROS_NEW_BACKEND_FLAG_ENABLED="true"
export IQE_MARKER_EXPRESSION="ros_smoke and (common or new_backend)"
export IBUTSU_SOURCE="ros-new-backend-pr"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if it can align with ros-backend-v2-pr-tests then it will be nice

@upadhyeammit
Copy link
Contributor

/retest

@upadhyeammit
Copy link
Contributor

test-v1

@saurabhpimpalgaokar123
Copy link
Contributor Author

/retest test-v1

@upadhyeammit upadhyeammit force-pushed the spimpalg-ros-dual-backend-testing branch from 688665c to ead0834 Compare November 21, 2025 13:48
@upadhyeammit upadhyeammit merged commit 09fddd4 into RedHatInsights:main Nov 21, 2025
14 of 15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants