Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我已经使用 Wildfly 8.1 实现了一个 REST api。端点类似于:
/rest/v1/users
在我对每个请求的实现中,我从数据库中读取用户并返回集合的 json 表示。
奇怪的想法是,如果我调用 api,我不会得到集合的唯一结果(即,对于每个请求,它随机提供一个旧值和新值之间的值)。这种情况一直持续到我重新启动服务器。
db接口是正确的,所以我的猜测是Wildfly正在缓存以前的数据,有可能吗?为什么它为不同的调用提供不同的结果?