Skip to content

Commit

Permalink
feat: add jaeger http trace format (open-telemetry#696)
Browse files Browse the repository at this point in the history
  • Loading branch information
vladislav-kiva committed Jan 16, 2020
1 parent 1a206cb commit b7a345f
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@
* limitations under the License.
*/

import { SpanContext, HttpTextFormat, TraceFlags } from "@opentelemetry/types";
import { SpanContext, HttpTextFormat, TraceFlags } from '@opentelemetry/types';

export const UBER_TRACE_ID_HEADER = "uber-trace-id";
export const UBER_TRACE_ID_HEADER = 'uber-trace-id';

/**
* Propagates {@link SpanContext} through Trace Context format propagation.
Expand Down Expand Up @@ -64,15 +64,15 @@ export class JaegerHttpTraceFormat implements HttpTextFormat {
* @return {string} - returns the input string without leading zeros.
**/
function removeLeadingZeros(input: string): string {
return input.replace(/^0+/, "");
return input.replace(/^0+/, '');
}

/**
* @param {string} serializedString - a serialized span context.
* @return {SpanContext} - returns a span context represented by the serializedString.
**/
function deserializeSpanContext(serializedString: string): SpanContext | null {
let headers = serializedString.split(":");
let headers = serializedString.split(':');
if (headers.length !== 4) {
return null;
}
Expand Down

0 comments on commit b7a345f

Please sign in to comment.