-
Notifications
You must be signed in to change notification settings - Fork 757
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
Support Queue events in tail #2397
Conversation
🦋 Changeset detectedLatest commit: 3fd7eff The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
A wrangler prerelease is available for testing. You can install this latest build in your project with: npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/6460339910/npm-package-wrangler-2397 You can reference the automatically updated head of this PR with: npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/prs/6460339910/npm-package-wrangler-2397 Or you can use npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/6460339910/npm-package-wrangler-2397 dev path/to/script.js Additional artifacts:npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/6460339910/npm-package-cloudflare-pages-shared-2397 Note that these links will no longer work once the GitHub Actions artifact expires.
| Please ensure constraints are pinned, and |
You seem to have your own local formatter/linter setup that is overriding ours, you can run the formatter command and save without formatting, which should clear this up 😃 |
35527ed
to
1460f27
Compare
Ugh it's just the classic "newline at the end of a file" vs "no newline at the end of a file" debate combined with me forgetting to run |
Codecov Report
@@ Coverage Diff @@
## main #2397 +/- ##
==========================================
- Coverage 75.35% 75.31% -0.05%
==========================================
Files 223 222 -1
Lines 12203 12188 -15
Branches 3154 3152 -2
==========================================
- Hits 9196 9179 -17
- Misses 3007 3009 +2
|
Sorry for not knowing offhand who's best to review this, @JacobMGEvans , but would you mind pointing me in the right direction? |
Anyone from the Wrangler team, I think it just got lost in the notifications |
Could you also add a changeset please 😊 |
1460f27
to
4fd4ca4
Compare
Ugh I'm just now seeing this never made it in :( I'll take a look at the conflicts soon, hopefully they were just due to support being added for other event types in the meantime. |
Ok, I think I got the conflicts fixed up appropriately. I'll try to find someone with merge privileges to review after ensuring CI passes. |
.changeset/warm-queens-taste.md
Outdated
@@ -0,0 +1,8 @@ | |||
--- | |||
"wrangler": patch |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"wrangler": patch | |
"wrangler": minor |
This should be a |
Queue events have an "event" section containing two fields -- "queue" and "batchSize", which contain the queue name and number of messages in the batch. Queue events can be distinguished from other events by the presence of the "queue" field, so that's what I do here. I've followed the example of RequestEvent more closely than either ScheduledEvent or AlarmEvent here, but am happy to change up the format if there's a reason to do so.
Thanks for the review, @penalosa! Fixed. |
Looks like CI is happy, should be good to merge whenever you're up for it (I don't have write access or I would myself). |
Queue events have an "event" section containing two fields -- "queue" and "batchSize", which contain the queue name and number of messages in the batch. Queue events can be distinguished from other events by the presence of the "queue" field, so that's what I do here.
I've followed the example of RequestEvent more closely than either ScheduledEvent or AlarmEvent here, but am happy to change up the format if there's a reason to do so.
@OilyLime @jbw1991