1 / 13

Performance, Scalability and Management

Performance, Scalability and Management. Topic Refining the object model Threading models Distributed callbacks Iterators Client-side cashing Monitoring performance. Refining the Object Model. Functional model Logical composition of functionality

frisco
Download Presentation

Performance, Scalability and Management

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Performance, Scalability and Management • Topic • Refining the object model • Threading models • Distributed callbacks • Iterators • Client-side cashing • Monitoring performance Performance Management

  2. Refining the Object Model • Functional model • Logical composition of functionality • Independent of actual distribution of objects and infrastructures • Implementation model or design • Association of logical objects with run-time entities Performance Management

  3. Room Booking Application Revisit • “Meeting” from interface to struct • View() • Array of CORBA object references (100 to 600 bytes) • Array of Java objects (~ 100 bytes) • Accessing details of a Meeting • Client makes two CORBA invocations on a remote Meeting object • Client access local Java objects • Booking a meeting • Complex • Create local object and pass it as an argument to a CORBA invocation • Cancel a meeting • Complex • One CORBA invocation Performance Management

  4. Threading Models • Threading in clients • Multithreaded clients Client delivers results creates, starts Client Proxy Proxy Thread Server Object Implementation Performance Management

  5. Threading in Servers • How can a server handle hundreds or thousands of concurrent client? • ORB provide automatic mechanisms for multithreaded servers • Single-threaded servers • Thread per connection • Thread per request (thread pools) Performance Management

  6. Single-threaded Server • Place incoming requests in a queue and process only one at a time • Poor performance • Potential of deadlocks (callback on a single-threaded client program) Client Client Client Client Proxy Client Proxy Client Proxy Object Adapter Worker thread Server Object Implementation Performance Management

  7. Thread-per-Connection Servers • Use one worker thread for each network connection Client Client Client Client Proxy Client Proxy Client Proxy Object Adapter Worker thread Worker thread Worker thread Object Implementation Server Performance Management

  8. Thread-per-Request Servers • Use one worker thread for each request • Max num of threads • Threads are returned to the pool after finishing processing requests • Creating thread overhead is minimized • Default model Client Client Client Client Proxy Client Proxy Client Proxy Thread Pool Object Adapter Worker thread Worker thread Worker thread Object Implementation Server Performance Management

  9. Distributed Callbacks • Break a synchronous call that returns some data into a pair of calls, i.e., a request and a response module hello { interface Callback { oneway void responseHello(in string str); }; interface GoodDay { oneway void requestHello(in Callback cb); } } Client delivers results calls Client Proxy Callback Object request response Server Object Implementation Performance Management

  10. Iterators • Transmission of large amount of data • Lazy evaluation • Pull and push Client delivers results calls Client Proxy Iterator Handler initial invocation pull creates Server Pull Iterator Object Implementation Performance Management

  11. Iterators • Push Client delivers results calls Client Proxy Iterator Handler initial invocation push creates Server Push Iterator Object Implementation Performance Management

  12. Client-Side Caching • Cache data at the client side --- optimize communication • Encapsulate the IDL-generated client proxy in a caching object • Use extensions provided by some ORB implementation Client Cache Proxy Client Proxy Client Proxy Smart Proxy Performance Management

  13. Monitoring Performance • Simple way: write code to take the time and compute the difference on both side • Mixing performance code with other logic • Make performance code conditional • CORBA portable interceptors framework Performance Management

More Related