Challenge Overview
In this challenge series we’ll be building a platform for Topcoder notifications that will be integrated into many products - challenge pages, Topcoder Connect, etc. The overall architecture is based on a message bus (Kafka). Each of the Topcoder services (ex project & challenge services, message service,..) will post events to the message bus (ex a challenge has been posted, challenge received a submission, user has joined a project, etc). We have built a simple REST service that will serve as a proxy to Kafka. Each of the client apps (community pages, Topcoder Connect, etc) will then have a separate notification server that will subscribe to Kafka topics, filter messages, store the notifications for each user and track notifications as new or seen (also implemented in a previous challenge).
Scope of this challenge is updating tc-message-service and tc-project-service to post events to the bus API.
Bus API is deployed at https://api.topcoder-dev.com/eventbus/topics and you can get api docs in the Github repo > https://github.com/topcoder-platform/tc-bus-api , dev branch. Posting to the bus api should not affect the API response - for example if the project is created, api response should be 200 success regardless of weather event is successfully posted to the bus api or not. Authorization tokens are provided bellow, but they should be configurable.
Sending notifications for posts/comments
Token for authentication to the bus api is eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJuYW1lIjoibWVzc2FnZS1zZXJ2aWNlIiwiaWF0IjoxNTEyNzQ3MDgyLCJleHAiOjE1MjEzODcwODJ9.yhdebtGrFWO_ltv0IycOosyU0WbQREtPSaiQyllX444
Events that should trigger posting to the bus api are create/update/delete topic or topic post with following events
notifications.connect.project.topic.created (event body: topicId, userHandle, projectId, topicTitle)
notifications.connect.project.topic.deleted (event body: topicId, userHandle, projectId)
notifications.connect.project.post.created (event body: topicId, postId, postContent, userHandle, projectId)
notifications.connect.project.post.edited (event body: topicId, postId, postContent, userHandle, projectId)
notifications.connect.project.post.deleted (event body: topicId, postId, userHandle, projectId)
Sending notifications for projects
Token for authentication to the bus api is eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJuYW1lIjoicHJvamVjdC1zZXJ2aWNlIiwiaWF0IjoxNTEyNzQ3MDgyLCJleHAiOjE1MjEzODcwODJ9.PHuNcFDaotGAL8RhQXQMdpL8yOKXxjB5DbBIodmt7RE
Events that should trigger posting to the bus api are create/update/delete project or topic post with following events
notifications.connect.project.created (event body: projectId, projectName) - same event body for events bellow
notifications.connect.project.submittedForReview
notifications.connect.project.approved
notifications.connect.project.paused
notifications.connect.project.completed
notifications.connect.project.canceled
notifications.connect.project.member.joined (event body: projectId, projectName, userHandle, userName) - same event body for events bellow
notifications.connect.project.member.left
notifications.connect.project.member.removed
notifications.connect.project.member.assignedAsOwner
notifications.connect.project.member.copilotJoined
notifications.connect.project.member.managerJoined
notifications.connect.project.linkCreated (event body: projectId, projectName, linkName, userHandle, userName)
notifications.connect.project.fileUploaded (event body: projectId, projectName, fileName, userHandle, userName)
notifications.connect.project.specificationModified (event body: projectId, projectName, userHandle, userName)
Your verification document should cover verifying that messages are posted to event bus. You can use a sample Kafka consumer posted in the forums to verify the messages.
Tc-message service repo is here, dev branch
Tc-project service repo is here, dev branch
Final Submission Guidelines
Submit a git patch for messages repoSubmit a git patch for projects repo
Submit updated Deployment guide
Submit a verification guide