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

GoExecutor should not return succ by default when completeness not eq 100 #2304

Closed
Crazyinging opened this issue Aug 17, 2020 · 5 comments
Closed
Assignees
Labels
wontfix Solution: this will not be worked on recently

Comments

@Crazyinging
Copy link
Contributor

image
As shown, GoExecutor return succ when completeness not eq 100. So it seems that the data received by the caller has the same effect as the missing data!
Reference: https://discuss.nebula-graph.com.cn/t/topic/1005

@Crazyinging
Copy link
Contributor Author

Crazyinging commented Aug 17, 2020

I think GoExecutor should return an exception when completeness not eq 100. And before that, graphd can retry some times on the failed storageds.

To be smarter, after reading the code, I think maybe it can be changed like this:

  1. GraphService add interface:
future_execute(int64_t sessionId, const std::string& stmt, const RequestConf& req_conf);

This interface will deal req_conf and call future_execute(int64_t sessionId, const std::string& stmt);

  1. Add:
class RequestConfig {
  private:
    int32_t graphd_retry_times_;   // Value range 0-3. Default is 0.
                                   // Indicates the number of retries from graphd to storaged.
    bool require_full_data_;       // When graphd can not get the full amount of data, whether to return exception or return the partial data that has been obtained. 
                                   // True(Default value): return exception when can not get the full amount of data. 
                                   // False: return the partial data that has been obtained.
};
  1. When GoExecutor::stepOut or GoExecutor::fetchVertexProps call storaged failed, retry according to RequestConfig.

@Crazyinging
Copy link
Contributor Author

Crazyinging commented Aug 17, 2020

Correspondingly, I use java client and java client's GraphClient should add new interface:

public ResultSet executeQuery(String statement, RequestConfig requestConfig)
            throws ConnectionException, NGQLException, TException;

@Crazyinging Crazyinging changed the title GoExecutor return succ when completeness not eq 100 GoExecutor should not return succ by default when completeness not eq 100 Aug 17, 2020
@dangleptr
Copy link
Contributor

Do we really need the configuration is on request level?

@Crazyinging
Copy link
Contributor Author

Crazyinging commented Aug 17, 2020

Do we really need the configuration is on request level?

Indeed, the request level may be over-designed.
Client level maybe be better, register RequestConfig when new client.

In addition, server level may not appropriate, such as adding configuration in the file nebula-graphd.conf, because the same service will have many users, and everyone's demands for stability may be different.

@CPWstatic CPWstatic added the wontfix Solution: this will not be worked on recently label Aug 9, 2021
@CPWstatic
Copy link
Contributor

This won't be fixed in nebula1.0. We had a configuration for it now in nebula2.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wontfix Solution: this will not be worked on recently
Projects
None yet
Development

No branches or pull requests

4 participants