You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
831 B
30 lines
831 B
|
2 weeks ago
|
package common.ecommerce.shared.audit;
|
||
|
|
|
||
|
|
import java.time.Clock;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 一次门面调用可供埋点读取的维度。渠道域的 {@code ChannelContext}、
|
||
|
|
* 仓库域的 {@code WarehouseContext} 都实现它,因此 {@link CallSupport} 可以放在
|
||
|
|
* 共享层,两个域各传自己的上下文。
|
||
|
|
*/
|
||
|
|
public interface CallScope {
|
||
|
|
|
||
|
|
/** <b>我方</b>链路 ID。 */
|
||
|
|
String requestId();
|
||
|
|
|
||
|
|
/** 接入通道名(渠道 provider / 仓库 provider)。 */
|
||
|
|
String providerName();
|
||
|
|
|
||
|
|
/** 业务平台名;仓库域没有平台概念,返回 null。 */
|
||
|
|
String platformName();
|
||
|
|
|
||
|
|
/** 宿主侧店铺 ID;仓库域返回 null。 */
|
||
|
|
String omsStoreId();
|
||
|
|
|
||
|
|
/** 渠道侧店铺 ID;仓库域返回 null。 */
|
||
|
|
String externalStoreId();
|
||
|
|
|
||
|
|
/** 取调用耗时的时钟。 */
|
||
|
|
Clock clock();
|
||
|
|
}
|