Closed thclark closed 10 months ago
Questions:
twined
? e.g. the children
field of a question is validated against a children schema inside twined
. One thing we could do is factor out the schema within twined
into Strands and then reference them in twined
but also in this schemadata
and attributes
keys but we'd have to transform Pub/Sub messages into the same JSON object format before we could validate them in one go. What do you think @thclark?To do in the next service communication breaking change:
null
. I'll make these all fully optional fields that can't be null
type
field to the question message type to make it consistent with the other message typesService.answer
(use .to_primitive
instead of .serialise
)is_question
octue/create-push-subscription
Other to-dos:
data
to event
Feature request
Use Case
We're doing load testing of
octue
services, and of a worker runningdjango_twined
to orchestrate them. So we want to simulate messages coming back to thedjango_twined
app, as if they were coming from running services.Current state
It's quite difficult to figure out how to make such messages. We're digging deep into the octue library to figure out how to generate realistic events for
log_record
s and other items.Wider issue
The set of messages that can come back from an octue service is not defined in any one place. This is a big deal, because this clear, opinionated API surrounding inter-service communication probably is our biggest selling point.
Also, it's worth pointing out that it doesn't matter if it's using the octue library or not. Any process that places events onto a pubsub topic in this format is behaving as an octue service. So fundamentally, this is how we create services in languages other than python.
Proposed solution
make_event(type="log_record", msg="name", ...)
or a similar API.