Пример #1
0
            public async global::System.Threading.Tasks.Task saveDependencies_ProcessAsync(int seqid, TProtocol iprot, TProtocol oprot, CancellationToken cancellationToken)
            {
                var args = new InternalStructs.saveDependenciesArgs();
                await args.ReadAsync(iprot, cancellationToken);

                await iprot.ReadMessageEndAsync(cancellationToken);

                try
                {
                    await _iAsync.saveDependenciesAsync(args.Dependencies, cancellationToken);
                }
                catch (TTransportException)
                {
                    throw;
                }
                catch (Exception ex)
                {
                    var sErr = $"Error occurred in {GetType().FullName}: {ex.Message}";
                    if (_logger != null)
                    {
                        _logger.LogError(ex, sErr);
                    }
                    else
                    {
                        Console.Error.WriteLine(sErr);
                    }
                }
            }
Пример #2
0
            public async global::System.Threading.Tasks.Task saveDependenciesAsync(global::Jaeger.Thrift.Agent.Dependencies dependencies, CancellationToken cancellationToken = default)
            {
                await OutputProtocol.WriteMessageBeginAsync(new TMessage("saveDependencies", TMessageType.Oneway, SeqId), cancellationToken);

                var args = new InternalStructs.saveDependenciesArgs()
                {
                    Dependencies = dependencies,
                };

                await args.WriteAsync(OutputProtocol, cancellationToken);

                await OutputProtocol.WriteMessageEndAsync(cancellationToken);

                await OutputProtocol.Transport.FlushAsync(cancellationToken);
            }