Skip to content

Fixing. Registry Reimplementation. #7

Open
SerhiiRI wants to merge 1 commit intofeat-anchor-patch-printfrom
feat-registry-redesign
Open

Fixing. Registry Reimplementation. #7
SerhiiRI wants to merge 1 commit intofeat-anchor-patch-printfrom
feat-registry-redesign

Conversation

@SerhiiRI
Copy link
Contributor

@SerhiiRI SerhiiRI commented Mar 7, 2026

From the user-perspective

Removed build-compiler
in future releases we'll replace compiler onto the advanced patch system which will be based on Reversed DAG structure passed in secondary time runned execute.

Registry
Registry is now a map-based structure ({:type spec, ...}) instead of a plain vector. registry-create accepts both formats:

;; vector — order = scan priority
(registry-create [from-spec fn-spec])
;; map — explicit keys
(registry-create {:commando/from from-spec, :commando/fn fn-spec})

registry-create support optional key :registry-order in which you may specify in which order need find-command parse items. (Needed in future features). If the user set only two of 5-th used in registry, it mean that explicitely declareted are going first and other just after(and order doesn't metter)
Built registry can be modified with registry-assoc / registry-dissoc without rebuilding from scratch.

From architecture perspective

how registry has been processed before? we took the registry -> injecting internal cmds -> parsing -> ...executing... -> remove external commands from registry. Work practicaly the same but take a look at the current registry structure:

{:registry           {:commando/from {} ...}
 :registry-order     [:commando/from]
 :registry-validated 1772923734358
 :registry-hash      -2017569654}

before passing this registry the parsing procedure we not extending :registy, instead we adding key :registry-runtime which contains _map,_values,_vec at the end of vector. After the execution is done, we removing :registry-runtime.

- REMOVED build-compiler. Will be introduced other options to optimize
secondary execution procedure.
- ADDED Registry. To already built registry user can attach/remove
additional CommandMapSpecs
- RENAMED Core, function `create-registry` onto `registry-create`
- ADDED Registry Tests.
@SerhiiRI SerhiiRI requested a review from Kaspazza March 7, 2026 22:51
@SerhiiRI SerhiiRI self-assigned this Mar 7, 2026
@SerhiiRI SerhiiRI changed the base branch from main to feat-anchor-patch-print March 7, 2026 23:56
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.

1 participant