What Is a Dynamic View Server?
An Rogue Wave® Server application consists of a
dynamic view server and a collection of
application components that share a common object structure, called the
object model. Components are designed to open dynamic views on the object model. Those
dynamic views are automatically notified of the state changes that occur in the object model.
A dynamic view server is an instance of the class
IlsMvServer (or of a derived class). It manages the set of
dynamic views that interface server objects with components and perform
interaction cycles. A component can be connected to the object model through one or several dynamic views. In a dynamic view server, each view is attached to an object of type
IlsMvComponentItf, whose role is to represent a component and its group of opened views locally within the server. An instance of
IlsMvUser is also associated with the instance of
IlsMvComponentItf. It can be used to enforce access rights or security policies.
We mentioned at the beginning of section
Overview that Rogue Wave Server applications can be either linked or distributed:
In a linked application, the dynamic view server and the component are implemented in the same process. In this mode, all the dynamic views opened on the server object model share the same instance of
IlsMvComponentItf. You can retrieve this instance using the static member function
IlsMvServer::GetDefaultComp.
In a distributed application, the dynamic view server is implemented in its owns process, while application components are distributed in their own different processes. Each instance of a component uses an instance of
IlsMvComponent to communicate with the object server. A component process can be connected to several dynamic view servers at the same time and, therefore, hold several instances of
IlsMvComponent, one per connection.
A component can itself be configured as a dynamic view server. In this way, you can build complete hierarchies and cooperative networks of object servers.
Rogue Wave Server has its own
main loop (see
IlsMvServer::Run) to implement the interaction cycle described in
Interaction Cycles. This
main loop consists of the following pseudo code:
while (!stopped) {
IlsMvProcess::GetSingleton().processRequest();
}
The instance of the IlsMvProcess subclass is responsible for processing the request and triggering the interaction cycle.
In a distributed application, the Rogue Wave Server interaction cycle is usually mixed with the main loop of the communication layer. In a server or in a component, the communication layer is represented by an instance of a subclass of IlsMvProcess. The Rogue Wave Server main loop delegates the request-processing task to the IlsMvProcess object, which usually waits for incoming events on the communication layer, decodes the received message, and executes it.
Version 6.3
Copyright © 2018, Rogue Wave Software, Inc. All Rights Reserved.