Skip to content

Commit 2570468

Browse files
Automated Code Change
PiperOrigin-RevId: 684783267
1 parent 4943f27 commit 2570468

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

tensorflow_serving/servables/hashmap/hashmap_source_adapter.cc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@ namespace {
3535
using Hashmap = std::unordered_map<string, string>;
3636

3737
// Populates a hashmap from a file located at 'path', in format 'format'.
38-
Status LoadHashmapFromFile(const string& path,
39-
const HashmapSourceAdapterConfig::Format& format,
40-
std::unique_ptr<Hashmap>* hashmap) {
38+
absl::Status LoadHashmapFromFile(
39+
const string& path, const HashmapSourceAdapterConfig::Format& format,
40+
std::unique_ptr<Hashmap>* hashmap) {
4141
hashmap->reset(new Hashmap);
4242
switch (format) {
4343
case HashmapSourceAdapterConfig::SIMPLE_CSV: {
@@ -61,7 +61,7 @@ Status LoadHashmapFromFile(const string& path,
6161
return errors::InvalidArgument("Unrecognized format enum value: ",
6262
format);
6363
}
64-
return Status();
64+
return absl::Status();
6565
}
6666

6767
} // namespace

tensorflow_serving/servables/hashmap/hashmap_source_adapter_test.cc

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,9 @@ namespace {
4444
using Hashmap = std::unordered_map<string, string>;
4545

4646
// Writes the given hashmap to a file.
47-
Status WriteHashmapToFile(const HashmapSourceAdapterConfig::Format format,
48-
const string& file_name, const Hashmap& hashmap) {
47+
absl::Status WriteHashmapToFile(const HashmapSourceAdapterConfig::Format format,
48+
const string& file_name,
49+
const Hashmap& hashmap) {
4950
std::unique_ptr<WritableFile> file;
5051
TF_RETURN_IF_ERROR(Env::Default()->NewWritableFile(file_name, &file));
5152
switch (format) {
@@ -63,7 +64,7 @@ Status WriteHashmapToFile(const HashmapSourceAdapterConfig::Format format,
6364
format);
6465
}
6566
TF_RETURN_IF_ERROR(file->Close());
66-
return Status();
67+
return absl::Status();
6768
}
6869

6970
TEST(HashmapSourceAdapter, Basic) {

0 commit comments

Comments
 (0)