Skip to content

Add connect exports/requests + translator type, and a media-source synthetic flag - #142

Merged
JonathanLennox merged 3 commits into
jitsi:masterfrom
JonathanLennox:connect-exports-requests
Jun 11, 2026
Merged

Add connect exports/requests + translator type, and a media-source synthetic flag#142
JonathanLennox merged 3 commits into
jitsi:masterfrom
JonathanLennox:connect-exports-requests

Conversation

@JonathanLennox

@JonathanLennox JonathanLennox commented Jun 10, 2026

Copy link
Copy Markdown
Member

Two related additions to the colibri2 extensions.

<connect>: exports/requests and translator type

  • <exports> / <requests> containers on <connect>, each holding <export> / <request> items that reference a source by its name attribute (the source-name idiom used by Capability / SourcePacketExtension):
    <connect url='...' protocol='mediajson' type='translator'>
      <exports><export name='523834112-a0'/><export name='2394a3432-a0'/></exports>
      <requests><request name='523834112-a0.en'/><request name='2394a3432-a0.hi'/></requests>
    </connect>
  • New translator connect type alongside recorder / transcriber.

<media-source>: synthetic flag

  • Optional synthetic boolean attribute on <media-source>, marking sources generated by the bridge rather than sent by an endpoint. Only emitted when true (defaults to false).

All of the above is wired through the XML providers and the Jackson-based JSON serializer/deserializer, with XML and bidirectional JSON round-trip test coverage.

Note

Rebased onto master now that #139 (the json-simple → Jackson migration) has merged. Supersedes #141, which was auto-closed when #139's branch was deleted.

🤖 Generated with Claude Code

JonathanLennox and others added 2 commits June 10, 2026 09:44
…onnect

Extend the colibri2 <connect> element with optional <exports> and
<requests> containers, each holding <export>/<request> items that
reference a source by its 'name' attribute (the source-name idiom used
by Capability/SourcePacketExtension). Also add a "translator" connect
type alongside recorder/transcriber.

Wire both through the XML provider and the Jackson-based JSON
serializer/deserializer (exports/requests as JSON string arrays).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add an optional 'synthetic' attribute to the colibri2 <media-source>
element, marking sources generated by the bridge rather than sent by an
endpoint. The attribute is only emitted when true (defaulting to false),
and is wired through the builder and the JSON serializer/deserializer.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@JonathanLennox JonathanLennox changed the title Add exports/requests source-name lists and translator type to connect Add connect exports/requests + translator type, and a media-source synthetic flag Jun 10, 2026
fun removePing() = getPing()?.let { removeChildExtension(it) }

fun getExports(): List<String> =
getChildExtensionsOfType(Exports::class.java).firstOrNull()?.getNames() ?: emptyList()

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can simplify using getChildExtension. Do you care about list vs set semantics here? Probably not

Addresses review feedback on jitsi#142.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@JonathanLennox
JonathanLennox merged commit 4281255 into jitsi:master Jun 11, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants