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: kafka adapter #342

Merged
merged 63 commits into from
Jan 25, 2023
Merged

feat: kafka adapter #342

merged 63 commits into from
Jan 25, 2023

Conversation

Ruchip16
Copy link
Contributor

@Ruchip16 Ruchip16 commented Oct 8, 2022

Description

Opening a draft PR for issue #256

  • Also, I did add a condition for Kafka protocol in the RegisterAdapters but it still results in the same error upon doing npm run dev in the cd examples/dummy folder in order to check whether our Kafka broker connects to the glee or not in that example

image

Related issue(s)

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Welcome to AsyncAPI. Thanks a lot for creating your first pull request. Please check out our contributors guide useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.

@Ruchip16 Ruchip16 changed the title Add Support for Kafka Adapter feat: Kafka Adapter Oct 8, 2022
@Souvikns
Copy link
Member

You have to run npm run dev on the root once for the changes to be built and update the /dist that the examples will be using.

Screenshot 2022-10-10 at 3 06 12 PM

Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

This is a great first approach, @Ruchip16 👏

Left some comments that I think can have a positive impact. Please, also remove all the package-lock.json changes from this PR. They shouldn't be part of this pull request 🙏

Keep up the great work!

asyncapi.yaml Outdated Show resolved Hide resolved
asyncapi.yaml Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Show resolved Hide resolved
src/registerAdapters.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

In general, I think your experimentation is going great. You have a big mess in the adapter file, so I recommend you clean it out and start slowly adding things that you are sure should be there. No commented code, no copy-pasted code, clean it all and start over.

src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
examples/dummy/package-lock.json Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

You're close to having a subscriber ready! Keep pushing! 💪

src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

Sorry, for some reason this suggestion wasn't added before 🤔

src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/lib/glee.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
examples/dummy - Copy/.env Outdated Show resolved Hide resolved
examples/dummy - Copy/customServer.js Outdated Show resolved Hide resolved
examples/dummy - Copy/glee.config.js Outdated Show resolved Hide resolved
examples/dummy - Copy/index.html Outdated Show resolved Hide resolved
examples/dummy - Copy/lifecycle/announceServer.ts Outdated Show resolved Hide resolved
examples/dummy - Copy/mosquitto.org.crt Outdated Show resolved Hide resolved
examples/dummy - Copy/socket.io.html Outdated Show resolved Hide resolved
Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

Alright, made a full review. It's looking good. Just apply these changes and we're done :)

package.json Outdated Show resolved Hide resolved
package.json Show resolved Hide resolved
docs/config-file.md Outdated Show resolved Hide resolved
docs/config-file.md Outdated Show resolved Hide resolved
examples/kafka-test/docker-compose.yml Outdated Show resolved Hide resolved
examples/kafka-test/local.env Outdated Show resolved Hide resolved
src/lib/functions.ts Outdated Show resolved Hide resolved
src/index.ts Outdated Show resolved Hide resolved
src/lib/message.ts Show resolved Hide resolved
src/registerAdapters.ts Outdated Show resolved Hide resolved
@Ruchip16 Ruchip16 changed the title feat: Kafka Adapter feat: kafka adapter Jan 24, 2023
@Ruchip16 Ruchip16 marked this pull request as ready for review January 24, 2023 09:28
Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

One more round. Let's go! It's close!

docs/config-file.md Outdated Show resolved Hide resolved
docs/config-file.md Outdated Show resolved Hide resolved
examples/kafka-test/glee.config.js Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
src/adapters/kafka/index.ts Outdated Show resolved Hide resolved
fmvilas
fmvilas previously approved these changes Jan 25, 2023
Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

LET'S GOOOO!

@coveralls
Copy link

coveralls commented Jan 25, 2023

Pull Request Test Coverage Report for Build 4007665241

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 4 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.02%) to 61.89%

Files with Coverage Reduction New Missed Lines %
src/lib/message.ts 1 90.32%
src/lib/glee.ts 3 90.12%
Totals Coverage Status
Change from base Build 3988887327: -0.02%
Covered Lines: 319
Relevant Lines: 441

💛 - Coveralls

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.0% 0.0% Duplication

Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

NOW YES! LET'S GOOOO 🚀

@Ruchip16
Copy link
Contributor Author

/rtm

@asyncapi-bot asyncapi-bot merged commit b2e9d52 into asyncapi:master Jan 25, 2023
@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 0.17.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@Ruchip16 Ruchip16 deleted the kafka-adapter branch January 25, 2023 18:29
@fmvilas
Copy link
Member

fmvilas commented Jan 25, 2023

Congratulations on finishing your mentorship program, Ruchi! 👏

@Ruchip16
Copy link
Contributor Author

Congratulations on finishing your mentorship program, Ruchi! 👏

Thank youuu ✨

@fmvilas fmvilas mentioned this pull request Feb 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants