Commit 10b73b1
authored
feat: align manifest proto schema with handler parameter schemas (#1840)
* feat: add aligned fields to OrganizationDefinition and MarketDataSetDefinition
Add legal_name, display_name, external_reference, external_reference_type
to OrganizationDefinition proto to match party.register_organization handler
parameters directly. Add validation_expression and resolution_key_expression
to MarketDataSetDefinition to match market_information.register_data_set
handler parameters.
Existing name field retained for backward compatibility.
* feat: pass aligned fields through executor and simplify Starlark script
Update OrganizationInput and MarketDataSetInput structs with new fields.
Update extractPartyAndAccounts with fallback chain (legal_name -> name,
display_name -> legal_name, external_reference -> code).
Update extractMarketData to pass validation/resolution expressions.
Update buildSagaInput to include all new fields in saga input map.
Simplify v1.3.0.star to use direct field passthrough instead of ad-hoc
translation from name/attributes.
* test: add tests for aligned organization and market data set fields
Test new proto fields pass through buildExecutorInput and buildSagaInput.
Test backward compatibility fallback when new fields are empty.
Verify validation_expression and resolution_key_expression propagation.
* fix: regenerate JSON schema and frontend proto, fix gofmt
Regenerate manifest.v1.schema.json to include new MarketDataSetDefinition
and OrganizationDefinition fields. Regenerate frontend TypeScript proto
bindings. Fix gofmt alignment in executor.go and grpc_handler_test.go.
* fix: complete legal_name fallback chain to include code
Add missing code fallback when both legal_name and name are empty, matching
the documented fallback chain: legal_name -> name -> code.
Add test for code-only organization definition.
* fix: make new manifest proto fields optional to avoid required constraint
New organization and market data set fields (legal_name, display_name,
external_reference, external_reference_type, validation_expression,
resolution_key_expression) must be optional in proto3 so they don't
appear in the generated JSON schema's required arrays. This preserves
backward compatibility for existing manifests that don't specify them.
* fix: make legacy name field optional in OrganizationDefinition
The deprecated name field should also be optional so manifests can use
only legal_name and display_name without being forced to provide name.
Addresses remaining CodeRabbit review feedback.
* revert: keep name field non-optional to avoid proto breaking change
Reverting the name field optional change since it triggers the Proto
Breaking Change Detection check (implicit to explicit presence is a
cardinality change). The name field was already required before this PR.
Making it optional would be a separate, intentional breaking change.
---------
Co-authored-by: Ben Coombs <bjcoombs@users.noreply.github.com>1 parent 9140d5d commit 10b73b1
9 files changed
Lines changed: 526 additions & 169 deletions
File tree
- api
- jsonschema
- proto/meridian/control_plane/v1
- frontend/src/api/gen/meridian/control_plane/v1
- services/control-plane/internal/applier
- defaults/apply_manifest
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
674 | 674 | | |
675 | 675 | | |
676 | 676 | | |
| 677 | + | |
| 678 | + | |
| 679 | + | |
| 680 | + | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
| 684 | + | |
677 | 685 | | |
678 | 686 | | |
679 | 687 | | |
| |||
795 | 803 | | |
796 | 804 | | |
797 | 805 | | |
798 | | - | |
| 806 | + | |
799 | 807 | | |
800 | 808 | | |
801 | 809 | | |
| |||
807 | 815 | | |
808 | 816 | | |
809 | 817 | | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
810 | 834 | | |
811 | 835 | | |
812 | 836 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
858 | 858 | | |
859 | 859 | | |
860 | 860 | | |
| 861 | + | |
| 862 | + | |
| 863 | + | |
| 864 | + | |
| 865 | + | |
| 866 | + | |
| 867 | + | |
| 868 | + | |
| 869 | + | |
| 870 | + | |
| 871 | + | |
| 872 | + | |
861 | 873 | | |
862 | 874 | | |
863 | 875 | | |
| |||
876 | 888 | | |
877 | 889 | | |
878 | 890 | | |
879 | | - | |
880 | | - | |
881 | | - | |
882 | | - | |
883 | | - | |
| 891 | + | |
| 892 | + | |
| 893 | + | |
884 | 894 | | |
885 | 895 | | |
886 | 896 | | |
| |||
893 | 903 | | |
894 | 904 | | |
895 | 905 | | |
| 906 | + | |
| 907 | + | |
| 908 | + | |
| 909 | + | |
| 910 | + | |
| 911 | + | |
| 912 | + | |
| 913 | + | |
| 914 | + | |
| 915 | + | |
| 916 | + | |
| 917 | + | |
| 918 | + | |
| 919 | + | |
| 920 | + | |
| 921 | + | |
| 922 | + | |
| 923 | + | |
| 924 | + | |
| 925 | + | |
896 | 926 | | |
897 | 927 | | |
898 | 928 | | |
| |||
Lines changed: 59 additions & 2 deletions
Large diffs are not rendered by default.
Lines changed: 9 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
171 | 171 | | |
172 | 172 | | |
173 | 173 | | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
174 | 178 | | |
175 | 179 | | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | 180 | | |
181 | | - | |
182 | | - | |
| 181 | + | |
| 182 | + | |
183 | 183 | | |
184 | | - | |
185 | | - | |
186 | | - | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
187 | 187 | | |
188 | 188 | | |
189 | 189 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
221 | 221 | | |
222 | 222 | | |
223 | 223 | | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | | - | |
229 | | - | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
230 | 232 | | |
231 | 233 | | |
232 | 234 | | |
233 | 235 | | |
234 | | - | |
235 | | - | |
236 | | - | |
237 | | - | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
238 | 244 | | |
239 | 245 | | |
240 | 246 | | |
| |||
484 | 490 | | |
485 | 491 | | |
486 | 492 | | |
487 | | - | |
488 | | - | |
489 | | - | |
490 | | - | |
491 | | - | |
492 | | - | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
493 | 501 | | |
494 | 502 | | |
495 | 503 | | |
| |||
515 | 523 | | |
516 | 524 | | |
517 | 525 | | |
518 | | - | |
519 | | - | |
520 | | - | |
521 | | - | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
522 | 534 | | |
523 | 535 | | |
524 | 536 | | |
| |||
Lines changed: 22 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
140 | 140 | | |
141 | 141 | | |
142 | 142 | | |
143 | | - | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
149 | 151 | | |
150 | 152 | | |
151 | 153 | | |
152 | 154 | | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
157 | 163 | | |
158 | 164 | | |
159 | 165 | | |
| |||
184 | 190 | | |
185 | 191 | | |
186 | 192 | | |
| 193 | + | |
| 194 | + | |
187 | 195 | | |
188 | 196 | | |
189 | 197 | | |
190 | 198 | | |
191 | 199 | | |
192 | 200 | | |
193 | 201 | | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
194 | 206 | | |
195 | 207 | | |
196 | 208 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
801 | 801 | | |
802 | 802 | | |
803 | 803 | | |
804 | | - | |
805 | | - | |
806 | | - | |
807 | | - | |
808 | | - | |
809 | | - | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
810 | 812 | | |
811 | 813 | | |
812 | 814 | | |
813 | 815 | | |
814 | 816 | | |
815 | 817 | | |
816 | 818 | | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
| 838 | + | |
| 839 | + | |
817 | 840 | | |
818 | | - | |
819 | | - | |
820 | | - | |
821 | | - | |
| 841 | + | |
| 842 | + | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
| 846 | + | |
| 847 | + | |
| 848 | + | |
822 | 849 | | |
823 | 850 | | |
824 | 851 | | |
| |||
0 commit comments