Skip to content

fix: resolve the issue of running hypertrace-alert-engine with postgres#276

Merged
kotharironak merged 7 commits intomainfrom
test-alert-engine
Aug 10, 2021
Merged

fix: resolve the issue of running hypertrace-alert-engine with postgres#276
kotharironak merged 7 commits intomainfrom
test-alert-engine

Conversation

@kotharironak
Copy link
Copy Markdown
Contributor

@kotharironak kotharironak commented Aug 9, 2021

Description

  • Move the hypertrace-alert-engine related changes to main docker-compose file so to use single docker-compose -f <> up command
  • make sure that both postgres and mongo setup uses same config files for channels + alerts

Testing

  • verified locally for both postgres + mongo

Checklist:

  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • Any dependent changes have been merged and published in downstream modules

Documentation

  • we will update accordingly

Comment thread docker/docker-compose.yml Outdated
condition: service_started

hypertrace-alert-engine:
image: hypertrace/hypertrace-alert-engine:1.0.7
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Once, we have fixed for latest version, we will remove the version tag.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Fixed! Could you check once and update here.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Done

Comment thread docker/configs/notification-rules.json Outdated
@kotharironak
Copy link
Copy Markdown
Contributor Author

@rish691 @JBAhire This changes make sure that our instruction of starting all services remains same - https://github.com/hypertrace/hypertrace#run-with-docker-compose

Comment thread docker/docker-compose.yml Outdated
container_name: hypertrace-alert-engine
# comment below two lines if you want to run alert-engine after modifying appropriate
# alert-rules.json and notification-rules.json files
entrypoint: [ "/bin/sh" ]
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

can you explain this part?

Comment thread docker/postgres/docker-compose.yml Outdated
# service_started, not service_healthy as pinot and deps can take longer than 60s to start
condition: service_started

hypertrace-alert-engine:
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@kotharironak , I see what you have done here. Ideally the way we had 2 different files earlier makes more sense considering I don't want alerting when I am trying it out for first time anyways because I am just trying out platform.

If directory or command is the problem, we can have duplicate files but let's have it in 2 steps. First step will be quick-start with Hypertrace and then try out alerting with Hypertrace. It will be cleaner way because you will need to stop and start the whole stack again in your case anyways but then there's additional thing to do that is comment these lines etc.

cc: @rish691

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@JBAhire In that case, we need a copy of the same files in postgres folder. I can do that as well. I will copy alerting files in postgres folder then.

Copy link
Copy Markdown
Contributor Author

@kotharironak kotharironak Aug 10, 2021

Choose a reason for hiding this comment

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

As discussed offline with @JBAhire, let's keep the default + postgres folder in sync. And, we will go with one simple command.
docker-compose -f <default file> -f <alerting file>

Comment thread docker/postgres/docker-compose.yml Outdated
# alert-rules.json and notification-rules.json files
entrypoint: [ "/bin/sh" ]
command: [ "-c",
"echo Pl. comment out entrypoint and command to run alert engine
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

In case we agree to go with this one, don't use abbreviations here.

@kotharironak
Copy link
Copy Markdown
Contributor Author

Verified using command as below,
docker-compose -f docker-compose.yml -f docker-compose.alerting.yml up

@kotharironak kotharironak merged commit 21ae8b4 into main Aug 10, 2021
@kotharironak kotharironak deleted the test-alert-engine branch August 10, 2021 06:12
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.

4 participants