skywalking-apache
Version:
The NodeJS agent for Apache SkyWalking
99 lines • 4.31 kB
JavaScript
// GENERATED CODE -- DO NOT EDIT!
// Original file comments:
//
// Licensed to the Apache Software Foundation (ASF) under one or more
// contributor license agreements. See the NOTICE file distributed with
// this work for additional information regarding copyright ownership.
// The ASF licenses this file to You 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.
//
//
;
var grpc = require('grpc');
var profile_Profile_pb = require('../profile/Profile_pb.js');
var common_Common_pb = require('../common/Common_pb.js');
function serialize_Commands(arg) {
if (!(arg instanceof common_Common_pb.Commands)) {
throw new Error('Expected argument of type Commands');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_Commands(buffer_arg) {
return common_Common_pb.Commands.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_ProfileTaskCommandQuery(arg) {
if (!(arg instanceof profile_Profile_pb.ProfileTaskCommandQuery)) {
throw new Error('Expected argument of type ProfileTaskCommandQuery');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_ProfileTaskCommandQuery(buffer_arg) {
return profile_Profile_pb.ProfileTaskCommandQuery.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_ProfileTaskFinishReport(arg) {
if (!(arg instanceof profile_Profile_pb.ProfileTaskFinishReport)) {
throw new Error('Expected argument of type ProfileTaskFinishReport');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_ProfileTaskFinishReport(buffer_arg) {
return profile_Profile_pb.ProfileTaskFinishReport.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_ThreadSnapshot(arg) {
if (!(arg instanceof profile_Profile_pb.ThreadSnapshot)) {
throw new Error('Expected argument of type ThreadSnapshot');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_ThreadSnapshot(buffer_arg) {
return profile_Profile_pb.ThreadSnapshot.deserializeBinary(new Uint8Array(buffer_arg));
}
var ProfileTaskService = exports.ProfileTaskService = {
// query all sniffer need to execute profile task commands
getProfileTaskCommands: {
path: '/ProfileTask/getProfileTaskCommands',
requestStream: false,
responseStream: false,
requestType: profile_Profile_pb.ProfileTaskCommandQuery,
responseType: common_Common_pb.Commands,
requestSerialize: serialize_ProfileTaskCommandQuery,
requestDeserialize: deserialize_ProfileTaskCommandQuery,
responseSerialize: serialize_Commands,
responseDeserialize: deserialize_Commands,
},
// collect dumped thread snapshot
collectSnapshot: {
path: '/ProfileTask/collectSnapshot',
requestStream: true,
responseStream: false,
requestType: profile_Profile_pb.ThreadSnapshot,
responseType: common_Common_pb.Commands,
requestSerialize: serialize_ThreadSnapshot,
requestDeserialize: deserialize_ThreadSnapshot,
responseSerialize: serialize_Commands,
responseDeserialize: deserialize_Commands,
},
// report profiling task finished
reportTaskFinish: {
path: '/ProfileTask/reportTaskFinish',
requestStream: false,
responseStream: false,
requestType: profile_Profile_pb.ProfileTaskFinishReport,
responseType: common_Common_pb.Commands,
requestSerialize: serialize_ProfileTaskFinishReport,
requestDeserialize: deserialize_ProfileTaskFinishReport,
responseSerialize: serialize_Commands,
responseDeserialize: deserialize_Commands,
},
};
exports.ProfileTaskClient = grpc.makeGenericClientConstructor(ProfileTaskService);
//# sourceMappingURL=Profile_grpc_pb.js.map