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

Replace requests to POST /action/index with POST /action/query where possible #111

Closed
isc-bsaviano opened this issue Dec 16, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@isc-bsaviano
Copy link
Contributor

Copied from #110 (comment)

For the specific case of hovering over a class name, I could replace the POST /action/index call with a POST /action/query call that only returns the exact info that I need (just the description). Testing on a local IRIS using Postman, here's what the benefit looks like for %Persistent:

POST /action/index (current behavior)

["%Library.Persistent.cls"]

Returns 76.25KB of data in ~14ms

POST /action/query (proposed behavior)

{
    "query": "SELECT Description FROM %Dictionary.CompiledClass WHERE Name = ?",
    "parameters": ["%Library.Persistent"]
}

Returns 684B of data in ~8ms

While this isn't a meaningful change when you're connected to a local IRIS or one on a fast network, transferring ~75KB fewer would likely be noticeable on a slower network like yours.

@isc-bsaviano isc-bsaviano added the enhancement New feature or request label Dec 16, 2020
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

No branches or pull requests

1 participant