-
Notifications
You must be signed in to change notification settings - Fork 149
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
geoprobe: simple geolocation probing refactoring #510
Conversation
.derive_ecdh_key() | ||
.expect("Should never failed with valid identity key; qed."); | ||
// TODO: currently assume contract key equals to local ecdh key | ||
let public_contract_ecdh_key = my_ecdh_key.clone().public(); |
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.
@shelvenzhou I think this one should be the target contract ecdh pubkey.
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.
This is the last remaining problem
UnknownError, | ||
} | ||
|
||
impl fmt::Display for GeoProbeError { |
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.
@kvinwang I guess there are easier ways to write Errors?
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.
I guess there are easier ways to write Errors?
There is a crate derive_more
to #[derive(Display)] for no_std and a thiserror
for std.
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.
We already have anyhow as pruntime is like a binary than a library. What do you suggest?
We have added some memory statistics in the get_info on the master. You can get the mem stat with this command: $ curl http://localhost:8000/get_info | jq -r '.payload | fromjson | .memory_usage'
{
"rust_peak_used": 174590146,
"rust_used": 51173836,
"total_peak_used": 278560768
} |
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.
Almost LGTM. Only left the ECDH key problem. I will chat with @shelvenzhou offline about it.
Btw, if you want to update the proto file reference, you just need to cd to the proto directory, use |
With geolocation enabled:
Without geolocation enabled::
Both memory statistics are sampled at the end of the e2e test. |
LGTM. We are ready to merge. The feature not enabled by default, right? |
Yes, disabled by default. |
More info in #498 .