16 #ifndef TENSORFLOW_SERVING_CORE_TEST_UTIL_FAKE_LOADER_H_
17 #define TENSORFLOW_SERVING_CORE_TEST_UTIL_FAKE_LOADER_H_
19 #include "tensorflow/core/lib/core/status.h"
20 #include "tensorflow/core/platform/mutex.h"
21 #include "tensorflow/core/platform/thread_annotations.h"
22 #include "tensorflow_serving/core/loader.h"
23 #include "tensorflow_serving/util/any_ptr.h"
25 namespace tensorflow {
46 Status
Load()
override;
52 static int num_fake_loaders();
55 static bool was_deleted_in_this_thread();
59 static thread_local
bool was_deleted_in_this_thread_;
62 static int num_fake_loaders_ TF_GUARDED_BY(num_fake_loaders_mu_);
63 static mutex num_fake_loaders_mu_;
70 const Status load_status_;
AnyPtr servable() override