Adds a platform-specific hook to start a monitoring exporter.
Change: 140909396
This commit is contained in:
parent
003e7d08aa
commit
2dfcc89d16
@ -228,12 +228,7 @@ cc_library(
|
||||
"lib/io/table_builder.h",
|
||||
"lib/io/table_options.h",
|
||||
"lib/math/math_util.h",
|
||||
"lib/monitoring/collected_metrics.h",
|
||||
"lib/monitoring/collection_registry.h",
|
||||
"lib/monitoring/counter.h",
|
||||
"lib/monitoring/metric_def.h",
|
||||
"lib/monitoring/mobile_counter.h",
|
||||
"lib/monitoring/mobile_sampler.h",
|
||||
"lib/monitoring/sampler.h",
|
||||
"lib/random/distribution_sampler.h",
|
||||
"lib/random/philox_random.h",
|
||||
@ -1089,6 +1084,11 @@ cc_library(
|
||||
"lib/io/zlib_compression_options.h",
|
||||
"lib/io/zlib_inputstream.h",
|
||||
"lib/io/zlib_outputbuffer.h",
|
||||
"lib/monitoring/collected_metrics.h",
|
||||
"lib/monitoring/collection_registry.h",
|
||||
"lib/monitoring/metric_def.h",
|
||||
"lib/monitoring/mobile_counter.h",
|
||||
"lib/monitoring/mobile_sampler.h",
|
||||
"lib/png/png_io.h",
|
||||
"lib/random/random.h",
|
||||
"lib/random/random_distributions.h",
|
||||
@ -1101,6 +1101,7 @@ cc_library(
|
||||
"platform/demangle.h",
|
||||
"platform/denormal.h",
|
||||
"platform/host_info.h",
|
||||
"platform/monitoring.h",
|
||||
"platform/platform.h",
|
||||
"platform/protobuf_internal.h",
|
||||
"platform/tensor_coding.h",
|
||||
|
24
tensorflow/core/platform/default/monitoring.cc
Normal file
24
tensorflow/core/platform/default/monitoring.cc
Normal file
@ -0,0 +1,24 @@
|
||||
/* Copyright 2016 The TensorFlow Authors. All Rights Reserved.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================*/
|
||||
|
||||
#include "tensorflow/core/platform/monitoring.h"
|
||||
|
||||
namespace tensorflow {
|
||||
namespace monitoring {
|
||||
|
||||
void StartExporter() {}
|
||||
|
||||
} // namespace monitoring
|
||||
} // namespace tensorflow
|
30
tensorflow/core/platform/monitoring.h
Normal file
30
tensorflow/core/platform/monitoring.h
Normal file
@ -0,0 +1,30 @@
|
||||
/* Copyright 2016 The TensorFlow Authors. All Rights Reserved.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================*/
|
||||
|
||||
#ifndef THIRD_PARTY_TENSORFLOW_CORE_PLATFORM_MONITORING_H_
|
||||
#define THIRD_PARTY_TENSORFLOW_CORE_PLATFORM_MONITORING_H_
|
||||
|
||||
namespace tensorflow {
|
||||
namespace monitoring {
|
||||
|
||||
// A hook to start periodically exporting metrics collected through our
|
||||
// monitoring API. The TensorFlow runtime will call this the first time a new
|
||||
// session is created using the NewSession method.
|
||||
void StartExporter();
|
||||
|
||||
} // namespace monitoring
|
||||
} // namespace tensorflow
|
||||
|
||||
#endif // THIRD_PARTY_TENSORFLOW_CORE_PLATFORM_MONITORING_H_
|
Loading…
Reference in New Issue
Block a user