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.
我在互联网上搜索过,但我总是看到“代理”这个词附加在另一个词上,比如代理服务器之类的。其他人告诉我,与 Hibernate 相关的代理与表元素的 ID 有关。但是代理本身是什么意思?
这个词proxy是指一个实体代替另一个实体。在上下文中,
proxy
代理服务器:充当两台机器之间的中介的服务器。
Hibernate 代理:Hibernate 通常不会返回数据,而是返回需要调用才能获取数据的代理。
在这两种情况下,代理都提供了某些好处(缓存结果、延迟执行直到必要)