| 95 | } |
| 96 | |
| 97 | Status GetIPAndPortFromUrl(const std::string& url, |
| 98 | std::string* ip, |
| 99 | int32_t* port) { |
| 100 | auto offset = url.find(":"); |
| 101 | if (offset == std::string::npos) { |
| 102 | return tensorflow::errors::Internal( |
| 103 | "Can't parse ip and port from url: ", url); |
| 104 | } |
| 105 | |
| 106 | *ip = url.substr(0, offset); |
| 107 | *port = atoi(url.substr(offset+1, url.length()).c_str()); |
| 108 | |
| 109 | return Status::OK(); |
| 110 | } |
| 111 | |
| 112 | FeatureStore* CreateFeatureStore(ModelConfig* config) { |
| 113 | if (config->feature_store_type == "redis") { |
no test coverage detected