fix node8 warnings
This commit is contained in:
Родитель
4319952bf4
Коммит
9655174d3e
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "applicationinsights-native-metrics",
|
||||
"version": "0.0.3",
|
||||
"version": "0.0.4",
|
||||
"lockfileVersion": 1,
|
||||
"requires": true,
|
||||
"dependencies": {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "applicationinsights-native-metrics",
|
||||
"description": "Native APM agent for the Application Insights Node.js SDK",
|
||||
"version": "0.0.3",
|
||||
"version": "0.0.4",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "Application Insights Developer Support",
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
namespace ai {
|
||||
|
||||
const uint64_t SEC_TO_MICRO = 1e6;
|
||||
const uint64_t SEC_TO_MICRO = 1000000;
|
||||
|
||||
/**
|
||||
* Get loop usage time in us
|
||||
|
|
|
@ -30,15 +30,15 @@ class Metric {
|
|||
auto resJson = Nan::New<v8::Object>();
|
||||
|
||||
Nan::Set(resJson, Nan::New("total").ToLocalChecked(),
|
||||
Nan::New<v8::Number>(total()));
|
||||
Nan::New<v8::Number>((double)total()));
|
||||
Nan::Set(resJson, Nan::New("min").ToLocalChecked(),
|
||||
Nan::New<v8::Number>(min()));
|
||||
Nan::New<v8::Number>((double)min()));
|
||||
Nan::Set(resJson, Nan::New("max").ToLocalChecked(),
|
||||
Nan::New<v8::Number>(max()));
|
||||
Nan::New<v8::Number>((double)max()));
|
||||
Nan::Set(resJson, Nan::New("count").ToLocalChecked(),
|
||||
Nan::New<v8::Number>(count()));
|
||||
Nan::New<v8::Number>((double)count()));
|
||||
Nan::Set(resJson, Nan::New("sumSquares").ToLocalChecked(),
|
||||
Nan::New<v8::Number>(sumSquares()));
|
||||
Nan::New<v8::Number>((double)sumSquares()));
|
||||
|
||||
return resJson;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче