0

服务接口不知道被谁用到,找不到调用方 怎么处理?

 2 years ago
source link: https://www.v2ex.com/t/831077
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

V2EX  ›  程序员

服务接口不知道被谁用到,找不到调用方 怎么处理?

  WillingXyz · 2 天前 · 4243 次点击

当前分为两种类型的接口,一种是给客户端使用的,一种是给其他服务使用的。 一个接口提供给外部使用之后,当要修改时,需要找到所有调用方。 问题是 不知道调用方是谁。

一个方案是 要求调用方传递一个标识,标识调用方是谁,如 appId/appName 。 该方案的缺点:

  1. 如果不强制传,调用方可能会不传
  2. 缺乏统一管理,只能通过日志筛选

另一个方案是 创建一个服务管理平台,当调用方需要用这个服务时,需要先在平台上创建,创建后生成 appId 或 appName ,然后调用方每次调用时传递该标识。 该方案的缺点:

  1. 有点麻烦,是否有必要

各位大佬们 当前都是怎么管理的


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK