-
Notifications
You must be signed in to change notification settings - Fork 100
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
rpc: add FindStorage #805
rpc: add FindStorage #805
Conversation
@superboyiii could you test it? |
@ixje I vote for 1 option |
They're not mutually exclusive. The server could set a maximum and the user could consume it at the maximum size or smaller. The question was whether we should support that or leave it hardcoded as is? |
Just FYI, a paging extension to getnepXXtransfers in NeoGo: |
I think it should be set in config.json so can be more flexible. |
Tested, works as the expected. |
@superboyiii I changed it so the value is configurable in the config only. Let me know if we want to add user control up to the configured maximum as well |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK. Now everything is OK for me.
@shargon ☝️ |
@ixje I think pageSize should configurable in config.json. Or event have this feature be able to be disabled. Reason being is that with tons of Users requesting to find storage it could slow down the server or timeout requests. |
It is now configurable in the config. Completely disabling can be done through the config by adding the method to the |
@shargon Review again please. |
* 'wss' of github.com:Liaojinghui/neo-modules: RpcServer: added GetContractState by contract id support (neo-project#813) rpc: add FindStorage (neo-project#805)
close #758
Arguments:
GetStorage()
the first argument is thecontract hash
orcontract id
search prefix
, base 64 encoded. Can be set to""
to return all storage.start
locationThe
pageSize
is currently fixed to 50. If the find results exceed 50 results it shall return thetruncated
key set totrue
and thenext
key set to thestart
location of the next page. This way a consumer can directly use the result ofjson["next"]
as 3rd parameter to continue where left off.Up for discussion:
pageSize
be configurable in the RpcServer config?pageSize
be configurable as parameter by the invoker?