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

Events: sender_type property to differentiate between multiple event sources #399

Merged

Conversation

martastain
Copy link
Member

@martastain martastain commented Oct 21, 2024

Endpoints that accepted "x-sender" header now also accept "x-sender-type".
sender_type is stored in the database in the separate field. and it is available in the eventmodel.

@jakubjezek001 @iLLiCiTiT do you need to be able to filter by it in enroll somehow? if so, how?

@martastain martastain linked an issue Oct 21, 2024 that may be closed by this pull request
@martastain martastain self-assigned this Oct 21, 2024
@martastain martastain added the type: feature Adding something new and exciting to the product label Oct 21, 2024
@martastain martastain marked this pull request as draft October 21, 2024 13:51
@martastain martastain marked this pull request as ready for review November 7, 2024 13:09
@iLLiCiTiT
Copy link
Member

iLLiCiTiT commented Nov 13, 2024

All works good, but I have one note, enrolled events don't have sender type filled from headers and enroll endpoint does not allow to fill it.

@martastain
Copy link
Member Author

All works good, but I have one note, enrolled events don't have sender type filled from headers and enroll endpoint does not allow to fill it.

Thanks. Good catch. I've added senderType to the request body and the enroll endpoint also supports providing sender and sender type values in headers. Both is optional, but when a value is specified both in the headers and the body, value from the body is used.

@martastain martastain requested a review from iLLiCiTiT November 13, 2024 16:17
@iLLiCiTiT
Copy link
Member

Thanks. Good catch. I've added senderType to the request body and the enroll endpoint also supports providing sender and sender type values in headers.

Nope, you didn't 🙂 , enroll still without sourceType.

@martastain
Copy link
Member Author

@iLLiCiTiT i ALMOST did. it was just one git commit and git push away :) sorry

@martastain martastain merged commit d30e199 into develop Nov 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: feature Adding something new and exciting to the product
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Entity change events: Be able to detect source of change
2 participants