Skip to content

Latest commit

 

History

History
17 lines (9 loc) · 1.21 KB

custom-query-layers.md

File metadata and controls

17 lines (9 loc) · 1.21 KB

Custom query layers in CTL

Adding a new backend

CTL can be extended with custom (user) query layers if needed. At this moment it can be done by forking.

Every query CTL uses, except of backend-specific ones, goes through a query handle.

A new backend option should be added, with corresponding initialization code

Replacing some queries in existing backend

Substituting the query layer for a few functions only (assuming the original backend remains available for initial connection) can be done without forking CTL.

ContractEnv contains a QueryHandle (inside a Reader), so a local call with a function that replaces some QueryHandle record entries will just work.