Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Npgsql parameter rewrite #78

Open
5 of 15 tasks
mgravell opened this issue Nov 16, 2023 · 1 comment · May be fixed by #84
Open
5 of 15 tasks

Npgsql parameter rewrite #78

mgravell opened this issue Nov 16, 2023 · 1 comment · May be fixed by #84
Labels
enhancement New feature or request

Comments

@mgravell
Copy link
Member

mgravell commented Nov 16, 2023

There are two parameter models in Npgsql - ordinal and nominal; we use nominal, but the ordinal API is much more efficient; we could ingest nominal const sql and rewrite it as ordinal

this should include splitting semi-colon multi-statements into DbBatch when possible

tasks:

  • basic generalized SQL parser
  • SQL syntax tests for postgresql peculiarities
  • basic exploration of batch concept
  • "real" batch concept (UnifiedBatch, should work with/without DbBatch API)
  • codegen (including turn-off-and-onable)
  • benchmark:
    • vanilla Dapper, parameterized single batch (Npgsql param rewrite)
    • vanilla Dapper, parameterized multi-batch (Npgsql param rewrite+split)
    • AOT Dapper, rewrite enabled, parameterized single batch, DbBatch disabled
    • AOT Dapper, rewrite enabled, parameterized multi batch, DbBatch disabled
    • AOT Dapper, rewrite enabled, parameterized single batch, DbBatch enabled
    • AOT Dapper, rewrite enabled, parameterized multi batch, DbBatch enabled
  • use parser in place of the regex in the regular code path? as an option with fallback?
  • docs
  • performance tuning of parser (I have a plan, don't ask; kind of a rewrite of the parser) (note this is not critical path)
@mgravell mgravell added the enhancement New feature or request label Nov 16, 2023
@mgravell
Copy link
Member Author

longer version of the work definition for this item (from Dapper thread): DapperLib/Dapper#1782 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant