What is a skeleton in a network?

走远了吗. 提交于 2020-01-11 11:37:47

问题


In a J2EE application, clients (applications, JSPs, servlets, JavaBeans) access entity beans via their remote interfaces. Thus, every client invocation potentially routes through network stubs and skeletons, even if the client and the enterprise bean are in the same JVM, OS, or machine.

What's a network skeleton? Some kind of proxy? I understand a stub to be a single use connection, is that correct?


回答1:


In RMI lingo, the skeleton is the generated object that sits on the server, accepts calls from the network, unmarshals them, and forwards them on to the business object.

So....

Client Business Object -> Stub -> Network -> Skeleton -> Server Business Object

It's a rather antiquated term, though, since this sort of stuff is much more automated than it used to be in early java, where skeletons had to be explicitly generated.




回答2:


When talking about RPC, stubs and skeletons are proxies for the remotely called procedure/method on the client/server respectively.

A client invokes a stub, that stub sends a protocol request to the server. The request arrives to the skeleton at the server, which then invokes the exported method.

Typically, stubs and skeletons are autogenerated from some IDL description by some tool



来源:https://stackoverflow.com/questions/6472176/what-is-a-skeleton-in-a-network

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!