-
Notifications
You must be signed in to change notification settings - Fork 2
APPS-33735: Add domain event bridge interface and data model (#135) #142
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
Conversation
vmaniar-rippling
commented
Jul 7, 2025
- Introduced DomainEventBridgeInterface for publishing and validating domain events.
- Added DomainEvent and UpdatedData models for structured event handling.
- Included ValidationResponse model for validation feedback.
* Introduced DomainEventBridgeInterface for publishing and validating domain events. * Added DomainEvent and UpdatedData models for structured event handling. * Included ValidationResponse model for validation feedback.
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.
Pull Request Overview
Adds interfaces and data models for domain event bridging to support structured publishing, transformation, and validation of domain events.
- Bumps package version to 0.64.
- Introduces
CustomObjectOutwardSync
andCustomObjectInwardSync
interfaces. - Defines
ErrorCode
enum and models:UpdatedData
,DomainObject
,ValidationResponse
, andPublishObjectResponse
.
Reviewed Changes
Copilot reviewed 4 out of 8 changed files in this pull request and generated no comments.
File | Description |
---|---|
pyproject.toml | Bumped version from 0.63 to 0.64. |
flux_sdk/custom_object_sync/outward_sync/interface.py | Added CustomObjectOutwardSync interface with methods to push, transform, and validate domain objects. |
flux_sdk/custom_object_sync/inward_sync/interface.py | Added CustomObjectInwardSync interface with methods to transform, validate, and fetch domain objects. |
flux_sdk/custom_object_sync/data_models/models.py | Added ErrorCode enum and Pydantic models for updated data, domain events, validation responses, and publish responses. |
Comments suppressed due to low confidence (7)
flux_sdk/custom_object_sync/outward_sync/interface.py:17
- The docstring for
push_object
is missing aReturns
section to describe thePublishObjectResponse
return value.
def push_object(payload: dict[str, Any]) -> PublishObjectResponse:
flux_sdk/custom_object_sync/outward_sync/interface.py:28
- [nitpick] Parameter name
object
shadows the built-inobject
. Consider renaming todomain_object
for clarity.
def transform_object(object: DomainObject) -> dict[str, Any]:
flux_sdk/custom_object_sync/outward_sync/interface.py:41
- Docstring
Args
describesevent
as adict
, but the signature usesobject: DomainObject
. Update the doc to match the parameter name and type.
def validate_object(object: DomainObject) -> ValidationResponse:
flux_sdk/custom_object_sync/inward_sync/interface.py:17
- [nitpick] Parameter name
object
shadows the built-in. Consider renaming toraw_object
orpayload
to avoid confusion.
def transform_object(object: dict[str, Any]) -> DomainObject:
flux_sdk/custom_object_sync/inward_sync/interface.py:17
- Docstring
Args
andReturns
descriptions are swapped relative to the signature; update them to match the input typedict[str, Any]
and return typeDomainObject
.
def transform_object(object: dict[str, Any]) -> DomainObject:
flux_sdk/custom_object_sync/inward_sync/interface.py:30
- [nitpick] Parameter name
object
shadows the built-in. Consider renaming topayload
orraw_object
for consistency.
def validate_object(object: dict[str, Any]) -> ValidationResponse:
flux_sdk/custom_object_sync/data_models/models.py:134
- Docstring describes
message
as a list of messages, but the field is defined as a singlestr
. Update the doc to reflect the correct type.
message: str | None = None