Ethereal-O opened a new issue, #329: URL: https://github.com/apache/incubator-hugegraph-computer/issues/329
### Feature Description (功能描述) When retrieving servers from an array, nil may occur and needs to be addressed. There are several options to choose from: 1. In obtaining the server function, simply output a prompt to the user Advantages: Compared to errors, it has more obvious information. Disadvantage: There is basically no processing, and errors will still occur when sending messages to the client in the future. 2. In the server function, return a default object that can execute the function without throwing an error, but can output prompt information Advantages: Unified processing, no need to modify a large amount of code. Disadvantage: It depends on the error handling mechanism of subsequent code. 3. Modify all calls to consider the issue of nil pointer Advantages: A relatively complete error handling mechanism. Disadvantage: There are too many logical changes that need to be made, and they are too repetitive. I am a newcomer and I am not sure what the best option is. Do you have any suggestions? thank. https://github.com/apache/incubator-hugegraph-computer/blob/1765fd9ebf6538b408f662b0a014d4b93053ced7/vermeer/apps/master/bl/server_manager.go#L81 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@hugegraph.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@hugegraph.apache.org For additional commands, e-mail: issues-h...@hugegraph.apache.org