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

feat(backend): spawn the notifications service + basic test #9464

Merged
merged 84 commits into from
Feb 14, 2025

Conversation

ntindle
Copy link
Member

@ntindle ntindle commented Feb 10, 2025

We want to send emails on a schedule, in response to events, and be expandable without being overbearing on the amount of effort to implement. We also want this to use rabbitmq and be easy for other services to send messages into.

This PR adds the first use of the service to simply show a log message

Changes 🏗️

  • Adds a new backend service for notifications
  • Adds first notification into the service -> Agent Execution
  • Adds spawning the notification service

Also

  • Adds RabbitMQ to CI so we can test stuff
  • Adds a minor fix for one of the migrations that I thought was causing failures, but isn't but the change is still useful

Checklist 📋

For code changes:

  • I have clearly listed my changes in the PR description
  • I have made a test plan
  • I have tested my changes according to the test plan:
    • Built and ran an agent and ensured the following log line appeared which shows the event would have sent an email
    2025-02-10 15:52:02,232 INFO  Processing notification: user_id='96b8d2f5-a036-437f-bd8e-ba8856028553' type=<NotificationType.AGENT_RUN: 'AGENT_RUN'> data=AgentRunData(agent_name='CalculatorBlock', credits_used=0.0, execution_time=0.0, graph_id='30e5f332-a092-4795-892a-b063a8c7bdd9', node_count=1) created_at=datetime.datetime(2025, 2, 10, 15, 52, 2, 162865)
    

For configuration changes:

  • .env.example is updated or already compatible with my changes
  • docker-compose.yml is updated or already compatible with my changes
  • I have included a list of my configuration changes in the PR description (under Changes)

None of the other ports are configurable via .env.example listing so left as is

Examples of configuration changes
  • Changing ports
  • Adding new services that need to communicate with each other
  • Secrets or environment variable changes
  • New or infrastructure changes such as databases

ntindle and others added 30 commits February 6, 2025 13:07
…r-compose' into ntindle/secrt-1087-attach-rabbit-mq-to-the-services-processes-similar-to-how
…r-compose' into ntindle/secrt-1087-attach-rabbit-mq-to-the-services-processes-similar-to-how
@ntindle ntindle added this pull request to the merge queue Feb 13, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Feb 13, 2025
@github-actions github-actions bot added the platform/frontend AutoGPT Platform - Front end label Feb 13, 2025
@github-actions github-actions bot removed the platform/frontend AutoGPT Platform - Front end label Feb 14, 2025
@ntindle ntindle enabled auto-merge February 14, 2025 03:56
@itsababseh itsababseh self-assigned this Feb 14, 2025
Copy link

@itsababseh itsababseh left a comment

Choose a reason for hiding this comment

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

Passed CI, multiple reviewed already and @ntindle gave the green light.

@ntindle ntindle added this pull request to the merge queue Feb 14, 2025
Merged via the queue into dev with commit 15275e2 Feb 14, 2025
27 checks passed
@ntindle ntindle deleted the ntindle/secrt-1077-add-email-service-smaller branch February 14, 2025 04:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

5 participants