本文整理汇总了Java中io.opentracing.Span类的典型用法代码示例。如果您正苦于以下问题:Java Span类的具体用法?Java Span怎么用?Java Span使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Span类属于io.opentracing包,在下文中一共展示了Span类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: zrevrangeByLex
import io.opentracing.Span; //导入依赖的package包/类
@Override
public Set<String> zrevrangeByLex(String key, String max, String min, int offset, int count) {
Span span = helper.buildSpan("zrevrangeByLex", key);
span.setTag("min", min);
span.setTag("max", max);
span.setTag("offset", offset);
span.setTag("count", count);
try {
return super.zrevrangeByLex(key, max, min, offset, count);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例2: georadiusByMember
import io.opentracing.Span; //导入依赖的package包/类
@Override
public List<GeoRadiusResponse> georadiusByMember(String key, String member, double radius,
GeoUnit unit, GeoRadiusParam param) {
Span span = helper.buildSpan("georadiusByMember", key);
span.setTag("member", member);
span.setTag("radius", radius);
span.setTag("unit", unit.name());
span.setTag("param", TracingHelper.toString(param.getByteParams()));
try {
return super.georadiusByMember(key, member, radius, unit, param);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例3: zrevrangeByScoreWithScores
import io.opentracing.Span; //导入依赖的package包/类
@Override
public Set<Tuple> zrevrangeByScoreWithScores(String key, double max, double min, int offset,
int count) {
Span span = helper.buildSpan("zrevrangeByScoreWithScores", key);
span.setTag("min", min);
span.setTag("max", max);
span.setTag("offset", offset);
span.setTag("count", count);
try {
return super.zrevrangeByScoreWithScores(key, max, min, offset, count);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例4: pfadd
import io.opentracing.Span; //导入依赖的package包/类
@Override
public Long pfadd(K key, V... values) {
Span span = helper.buildSpan("pfadd", key);
try {
return commands.pfadd(key, values);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例5: del
import io.opentracing.Span; //导入依赖的package包/类
@Override
public Long del(String key) {
Span span = helper.buildSpan("del", key);
try {
return super.del(key);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例6: brpop
import io.opentracing.Span; //导入依赖的package包/类
@Override
public List<String> brpop(int timeout, String... keys) {
Span span = helper.buildSpan("brpop", keys);
span.setTag("timeout", timeout);
try {
return super.brpop(timeout, keys);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例7: bitpos
import io.opentracing.Span; //导入依赖的package包/类
@Override
public RedisFuture<Long> bitpos(K key, boolean state, long start) {
Span span = helper.buildSpan("bitpos", key);
span.setTag("state", state);
span.setTag("start", start);
return setCompleteAction(commands.bitpos(key, state, start), span);
}
示例8: bitpos
import io.opentracing.Span; //导入依赖的package包/类
@Override
public Long bitpos(byte[] key, boolean value) {
Span span = helper.buildSpan("bitpos", key);
span.setTag("value", value);
try {
return super.bitpos(key, value);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例9: sdiff
import io.opentracing.Span; //导入依赖的package包/类
@Override
public Set<String> sdiff(String... keys) {
Span span = helper.buildSpan("sdiff", keys);
try {
return super.sdiff(keys);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例10: type
import io.opentracing.Span; //导入依赖的package包/类
@Override
public String type(String key) {
Span span = helper.buildSpan("type", key);
try {
return super.type(key);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例11: slowlogLen
import io.opentracing.Span; //导入依赖的package包/类
@Override
public Long slowlogLen() {
Span span = helper.buildSpan("slowlogLen");
try {
return super.slowlogLen();
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例12: geoadd
import io.opentracing.Span; //导入依赖的package包/类
@Override
public Long geoadd(String key, Map<String, GeoCoordinate> memberCoordinateMap) {
Span span = helper.buildSpan("geoadd");
span.setTag("memberCoordinateMap", TracingHelper.toString(memberCoordinateMap));
try {
return super.geoadd(key, memberCoordinateMap);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例13: zrevrangebyscore
import io.opentracing.Span; //导入依赖的package包/类
@Override
public RedisFuture<List<V>> zrevrangebyscore(K key,
Range<? extends Number> range) {
Span span = helper.buildSpan("zrevrangebyscore", key);
span.setTag("range", nullable(range));
return setCompleteAction(commands.zrevrangebyscore(key, range), span);
}
示例14: clientSetname
import io.opentracing.Span; //导入依赖的package包/类
@Override
public String clientSetname(String name) {
Span span = helper.buildSpan("clientSetname");
span.setTag("name", name);
try {
return super.clientSetname(name);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}
示例15: sscan
import io.opentracing.Span; //导入依赖的package包/类
@Override
public ScanResult<String> sscan(String key, String cursor, ScanParams params) {
Span span = helper.buildSpan("sscan", key);
span.setTag("cursor", cursor);
span.setTag("params", TracingHelper.toString(params.getParams()));
try {
return super.sscan(key, cursor, params);
} catch (Exception e) {
onError(e, span);
throw e;
} finally {
span.finish();
}
}