Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Add Service Portal to list of non-tracer apps #15022

Merged
merged 2 commits into from
May 30, 2024

Conversation

peturgq
Copy link
Member

@peturgq peturgq commented May 30, 2024

...

Attach a link to issue if relevant

What

Specify what you're trying to achieve

Why

Specify why you need to achieve this

Screenshots / Gifs

Attach Screenshots / Gifs to help reviewers understand the scope of the pull request

Checklist:

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • Formatting passes locally with my changes
  • I have rebased against main before asking for a review

Summary by CodeRabbit

  • Configuration Changes

    • Updated environment settings to remove the -r dd-trace/init option for development, production, and staging environments, optimizing memory usage.
  • New Features

    • Added a new service named 'service-portal' to the list of services in our infrastructure configuration.

@peturgq peturgq requested a review from a team as a code owner May 30, 2024 14:47
Copy link
Contributor

coderabbitai bot commented May 30, 2024

Walkthrough

The recent changes primarily involve the removal of the -r dd-trace/init option from the NODE_OPTIONS environment variable in various configuration files (dev, prod, and staging) under the charts/islandis directory. Additionally, a new service named 'service-portal' has been added to the serializeService function in the map-to-helm-values.ts file in the infrastructure code.

Changes

File Path Change Summary
charts/islandis/values.dev.yaml Removed the -r dd-trace/init option from the NODE_OPTIONS environment variable.
charts/islandis/values.prod.yaml Removed the -r dd-trace/init option from the NODE_OPTIONS environment variable.
charts/islandis/values.staging.yaml Removed the -r dd-trace/init option from the NODE_OPTIONS environment variable.
infra/src/dsl/output-generators/map-to-helm-values.ts Added a new service named 'service-portal' to the list of services in the serializeService function.

Sequence Diagram(s) (Beta)

No sequence diagrams generated as the changes are primarily configuration adjustments and a minor addition to an existing function.


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Member

@lodmfjord lodmfjord left a comment

Choose a reason for hiding this comment

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

LGTM

@peturgq peturgq added deprecated:automerge (Disabled) Merge this PR as soon as all checks pass high priority VIP-Kodiak PR labels May 30, 2024
@datadog-island-is
Copy link

Datadog Report

All test runs 5efecc2 🔗

2 Total Test Services: 0 Failed, 1 Passed
➡️ Test Sessions change in coverage: 3 no change

Test Services
Service Name Failed Known Flaky New Flaky Passed Skipped Total Time Code Coverage Change Test Service View
api 0 0 0 4 0 2.88s 1 no change Link
service-portal-health 0 0 0 0 0 1.11s 1 no change Link

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Outside diff range and nitpick comments (4)
infra/src/dsl/output-generators/map-to-helm-values.ts (4)

Line range hint 509-516: Replace forEach with for...of for better readability and modern JavaScript practices.

- volumes.forEach((volume) => {
+ for (const volume of volumes) {

Line range hint 262-262: Simplify the computed expressions to enhance readability and maintainability.

- env['REDIS_URL_NODE_01'] = serviceDef.redis.host ?? env1.redisHost
+ env['REDIS_URL_NODE_01'] = serviceDef.redis.host || env1.redisHost

Also applies to: 318-318, 319-319, 321-321, 327-327, 328-328, 334-334


Line range hint 163-163: Consider removing or properly handling non-null assertions to avoid potential runtime errors.

Also applies to: 524-524, 528-528


Line range hint 231-231: Avoid using spread syntax on accumulators to improve performance.

- return { ...acc, [`${ingressName}-alb`]: ingress }
+ acc[`${ingressName}-alb`] = ingress
+ return acc
Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between ffda333 and 9e27f56.

Files selected for processing (4)
  • charts/islandis/values.dev.yaml (1 hunks)
  • charts/islandis/values.prod.yaml (1 hunks)
  • charts/islandis/values.staging.yaml (1 hunks)
  • infra/src/dsl/output-generators/map-to-helm-values.ts (1 hunks)
Files skipped from review due to trivial changes (3)
  • charts/islandis/values.dev.yaml
  • charts/islandis/values.prod.yaml
  • charts/islandis/values.staging.yaml
Additional context used
Path-based instructions (1)
infra/src/dsl/output-generators/map-to-helm-values.ts (1)

Pattern infra/src/dsl/**/*: "Confirm that the code adheres to the following:

  • The clarity and expressiveness of the DSL syntax.
  • Integration with Helm charts and Kubernetes resources.
  • Documentation on how to use the DSL to create complex Helm values."
Biome
infra/src/dsl/output-generators/map-to-helm-values.ts

[error] 162-165: Prefer for...of instead of forEach.


[error] 163-163: Forbidden non-null assertion.


[error] 262-262: The computed expression can be simplified without the use of a string literal.


[error] 283-288: This else clause can be omitted because previous branches break early.


[error] 318-318: The computed expression can be simplified without the use of a string literal.


[error] 319-319: The computed expression can be simplified without the use of a string literal.


[error] 321-321: The computed expression can be simplified without the use of a string literal.


[error] 327-327: The computed expression can be simplified without the use of a string literal.


[error] 328-328: The computed expression can be simplified without the use of a string literal.


[error] 334-334: The computed expression can be simplified without the use of a string literal.


[error] 387-387: Invalid typeof comparison value: this expression is not a string literal


[error] 441-443: This else clause can be omitted because previous branches break early.


[error] 459-459: Do not use template literals if interpolation and special-character handling are not needed.


[error] 509-516: Prefer for...of instead of forEach.


[error] 524-524: Forbidden non-null assertion.


[error] 528-528: Forbidden non-null assertion.


[error] 1-9: All these imports are only used as types.


[error] 9-18: All these imports are only used as types.


[error] 18-19: All these imports are only used as types.


[error] 231-231: Avoid the use of spread (...) syntax on accumulators.

Additional comments not posted (2)
infra/src/dsl/output-generators/map-to-helm-values.ts (2)

53-53: Addition of 'service-portal' to the non-tracer apps list is correctly implemented.


53-53: Ensure that the logic for excluding tracer initialization for non-tracer apps is thoroughly tested, especially with the new addition.

@kodiakhq kodiakhq bot merged commit f6e09da into main May 30, 2024
33 checks passed
@kodiakhq kodiakhq bot deleted the fix/add-service-portal-to-non-tracer branch May 30, 2024 15:22
peturgq added a commit that referenced this pull request May 31, 2024
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
@peturgq peturgq mentioned this pull request May 31, 2024
6 tasks
peturgq added a commit that referenced this pull request May 31, 2024
* chore: Enable tracer only when its used (#15011)

* chore: Enable tracer only when its used

* rename to list

* chore: nx format:write update dirty files

* fix: typo

* fix: tests

---------

Co-authored-by: andes-it <builders@andes.is>

* fix: Add Service Portal to list of non-tracer apps (#15022)

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>

* chore: charts update dirty files

---------

Co-authored-by: andes-it <builders@andes.is>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deprecated:automerge (Disabled) Merge this PR as soon as all checks pass high priority VIP-Kodiak PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants