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

Add support for Kinesis #46

Merged
merged 3 commits into from
May 22, 2023
Merged

Add support for Kinesis #46

merged 3 commits into from
May 22, 2023

Conversation

oleiade
Copy link
Member

@oleiade oleiade commented May 5, 2023

This Pull Request is based on the excellent work done by @autometa101 in #33. It introduces support for a subset of the AWS Kinesis API.

All the credit goes to @autometa101 for this, as we only refactored, slightly changed a few APIs, documented, and reorganized the code in this PR.

@autometa101, if you have the time, I would appreciate it if you could take it for a spin and let us know if it works as intended 🙇🏻

closes #33

@oleiade oleiade changed the title Feature/kinesis Add support for Kinesis May 5, 2023
@oleiade oleiade requested a review from immavalls May 5, 2023 14:13
@oleiade oleiade self-assigned this May 5, 2023
@oleiade oleiade added the enhancement New feature or request label May 5, 2023
@oleiade oleiade added this to the 0.8.0 milestone May 5, 2023
@oleiade
Copy link
Member Author

oleiade commented May 5, 2023

✋🏻 We will need to have a documentation branch ready before we merge this ✋🏻

@igracia
Copy link

igracia commented May 9, 2023

Hi @oleiade! I was looking precisely for this support and run into your PR. Thank you! Decided to give it a try but run into some issues I've been unable to fix. Sharing here in case it helps! The tests fail with the following error

 █ 04. publish to kinesis Stream

       ✗ Exception raised "GoError: Error: Either streamName or streamARN must be provided"
        ↳  0% — ✓ 0 / ✗ 1

     █ 05. Gets an Amazon Kinesis read all data 

       ✗ Exception raised "GoError: KinesisServiceError: Invalid message body: Could not decode JSON: {
  "ShardIterator" : {
    "ShardIterator" : "AAAAAAAAAAFmqwhoAfhE8MD13BXmQX1Ih9VZi4y1LyauMGHHn7dAS6mus1maw43HnDAqCWJBITfLCVFU5Hlc2I5/bBVx/ztxgE+ql5aZ+e4bb0P7XMBe93AZdQtOznPAvjkna2+Zp1IomJ2qLEHM3y+BwbUJDGx0vxSHAKTEldoEPxTQJ+iIlXBy5yRe1ZS4vhgMXhbaMEOLIu3/h9/oO/h4iSPuGf75"
  }
}"
        ↳  0% — ✓ 0 / ✗ 1

     █ 06. Delete kinesis Stream

       ✗ Exception raised "GoError: KinesisServiceError: Invalid message body: Could not decode JSON: {
  "StreamName" : {
    "StreamName" : "kinesis-test-stream-dummy"
  }
}"
        ↳  0% — ✓ 0 / ✗ 1

I'm using Node.js v19.9.0 on an M1 MacBook. I see the tests are failing in the build system with the same message too (although the check is green?), so I'm guessing this is not something privy to my box. Can I help you debug this somehow?

@oleiade
Copy link
Member Author

oleiade commented May 9, 2023

Hey @igracia 👋🏻

Thanks for taking this code out for a spin 🚗 Much appreciated! 👏🏻

We are actively looking into the errors you've reported, and I'll let you know if we could use some further support from you 🙇🏻

@oleiade oleiade force-pushed the feature/kinesis branch 2 times, most recently from 171deea to 69156e6 Compare May 9, 2023 16:21
@oleiade
Copy link
Member Author

oleiade commented May 9, 2023

@immavalls @igracia I have pushed some changes to the branch which address the issues related to the tests failing. It should at least work as intended on that front now 👍🏻 Could you please take it out for a spin and let me know if it works for you? 🙏🏻 🙇🏻

@igracia
Copy link

igracia commented May 11, 2023

@oleiade It works for me now! I was having an issue with the putRecords request on my side this time, so it took a couple of tries before I checked your test class. Thanks for the quick fix, really appreciate it!

I'm currently running this against a localstack v2.0.1 docker container. I'm setting up all my infra through docker compose, and the goal is to be able to run load tests locally in the same way as ew'd do in any other env, hence the liking for your plugin.

tests/internal/kinesis.js Outdated Show resolved Hide resolved
@igracia
Copy link

igracia commented May 22, 2023

LGTM! I'm having some issues with base64 encoding of protobuf data, but t's not related to this PR. Otherwise it's working great!

@oleiade oleiade merged commit 28479bd into main May 22, 2023
2 checks passed
@oleiade oleiade deleted the feature/kinesis branch May 22, 2023 11:09
@oleiade oleiade restored the feature/kinesis branch August 2, 2023 12:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants