Repository navigation
Conversation
… from the fields a map has A map states its boundaries from its own code and leaves the far side unsaid: the far side is another distribution at a version of its own. bamboo.codemap.bind reads two or more maps together and says what each crossing reaches, with no knowledge of the plugins that built them. A map uses what another system has and offers what it has itself. A port is one of either, read from the map's own fields, and a use binds to an offer of the same kind and key: * http: an outbound boundary whose far side is a URL path, to an endpoint (MapFragment.endpoints) and the inbound boundary of its function; * call: an outbound boundary whose far side is a callable of a package, to a function a map names. A client library is a map like any other, so a call binds to the library and the library's request to the server; * table: a shared_table boundary -- schema.table, or the model class the code imports -- to an entity's tables, a table record and each subject as a column. The schema is the deployment's, so a table binds by its own name and the binding notes both spellings; * message: an outbound message boundary and the types sent to it (message_edges), to each type a receiver takes (message_receivers), where the destinations agree or the receiver states none. In an outbound boundary a name spelled file::name is the map's own function and any other is the far side's, whichever of interface and calls_out holds it: PanDA's map names the boundary by its own method, a map of code that calls out from anywhere names it by the outside interface. A use nothing offers is left unbound with the reason -- no map given covers the system, the map that covers it has no such node, the receiver has no handler for the type. A message type a receiver takes that no map sends is listed apart. The result is Bindings, an artifact of its own stamped with each map's version: a binding holds between two versions and a dump is one version's, so the maps are not changed and BoundaryNode.resolution is not written; Bindings.resolution answers it. A new kind of crossing is a reader of ports (register_reader) and, where the key alone does not decide, a matcher. bamboo bind-maps panda.json other.json ... --dump bindings.json The tests build four maps by hand -- a server shaped as PanDA's plugin shapes one, a client library, two applications -- and run no plugin. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…eport gives one row per key reached PanDA's entity of jedi_tasks lists the table as the corpus spells it, JEDI_Tasks and jedi_tasks, and each spelling was an offer under the same key, so a use of the table bound to it twice. One offer per key of an entity. The report merges the bindings of one key to one node, whichever boundaries of the source cross to it. Read on real maps: PanDA (panda-server master, 131 endpoints, 72 entities, 741 subjects) with a client library's and two applications' binds 206 crossings -- every request of the library to its endpoint, an application's calls to the library, 17 of the 19 PanDA tables the applications name with 111 of their columns to subjects -- in two seconds. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This was referenced Nov 24, 2026
Draft
Draft
Draft
Draft
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Merge order
This PR: merge at any time. It needs none of the others and none of them needs it: it reads map dumps, whatever built them. The numbers under Read on real maps need the plugins of #50, #51 and #54 to reproduce, not to merge.
Merging one of #50, #51, #54 before #52 would bring #52's commits in with it; the rest then still merge cleanly. All five were merged together in a scratch branch with no conflict.
Summary
A map states its boundaries from its own code and leaves the far side unsaid.
bamboo bind-mapsreads two or more map dumps together and says what each crossing reaches. It needs nothing of the plugins that built the maps: it reads the fields every map is made of.A map uses what another system has and offers what it has itself. A port is one of either, read from the map, and a use binds to an offer of the same kind and key.
httpMapFragment.endpoints), with its inbound boundary/api/v1/job/killcallpandaclient.Client.submitJobstableshared_tableboundary:schema.table, or the model class the code importsjedi_tasksmessagemessageboundary and the types sent to it (message_edges)message_receivers)file::nameis the map's own function and any other is the far side's, whichever ofinterfaceandcalls_outholds it. PanDA's map names the boundary by its own method; a map of code that calls out from anywhere names it by the outside interface.ATLAS_PANDA/doma_panda), so a table binds by its own name and the binding notes both spellings.Bindings, an artifact of its own stamped with each map's version. The maps are not changed andBoundaryNode.resolutionis not written: a binding holds between two versions and a dump is one version's.register_reader) and, where the key alone does not decide, a matcher.Changes
bamboo/codemap/bind.py— ports, readers, matchers,bind()bamboo/scripts/bind_maps.py,bamboo/cli.py— thebind-mapscommandtests/test_codemap_bind.py— four maps built by hand (a server shaped as PanDA's plugin shapes one, a client library, two applications); no plugin is runwebsite/.../code-map-building.md— "Binding maps to one another"Read on real maps
PanDA (panda-server master 78463a7: 131 endpoints, 72 entities, 741 subjects, 185 boundaries) bound with a client library's map and two applications' maps (the other
codemap-*branches): 206 crossings over 8 channels, in two seconds.jobsactive4.jobstatus→JobSpec.jobStatus, which 37 PanDA functions write);Test plan
pytest tests/test_codemap_bind.py— 15 passedscripts/mypy_ratchet.py check— 0 errors; black and ruff clean on the touched filescodemap-*branches in a scratch branch: no conflict, 66 tests pass🤖 Generated with Claude Code