Chapter 12 Calling EAServer Component Methods from PowerDynamo


How do EAServer and PowerDynamo work together?

Dynamo is an application server that dynamically generates HTML pages which are then delivered to Web browsers through an HTTP protocol.

EAServer, on the other hand, is a component transaction server that can serve up components to any client that makes MASP, Java, CORBA C++, ActiveX, or C method calls. EAServer components contain business logic that is completely independent of the client or clients accessing the component. In addition, you can configure EAServer to host your Dynamo Web pages, making them accessible from a Web browser. See the EAServer System Administration Guide for information about hosting Dynamo Web pages.

The combination of PowerDynamo and EAServer allows you to create pure HTML applications that dynamically make use of business logic from EAServer components.

Figure 12-1 demonstrates a scenario in which a Dynamo client connects to EAServer to process a Dynamo script that contains a Method As Stored Procedures (MASP) call to a EAServer component.

Figure 12-1: Dynamo client calling EAServer component

These steps correspond to the numbers in the diagram:

  1. A browser requests a Web page, which is a PowerDynamo script that contains HTML, SQL queries, and a MASP call to an EAServer component.
  2. The Web server passes the request to Dynamo.
  3. The script is retrieved from the Web site (not shown in graphic). The HTML in the Dynamo script and the SQL query begin to be processed.
  4. An ODBC or Open Client connection is made to a database to retrieve the necessary information for the SQL query.
  5. The data is returned to PowerDynamo. Processing continues until the EAServer component call is encountered.
  6. Because a MASP call is being made, an ODBC or Open Client connection is made to EAServer to access the EAServer component and called method.
  7. The component method is executed. If the method requires database access, a connection is made to a database to retrieve the appropriate data.
  8. The data is returned to EAServer through an ODBC, Open Client, or JDBC connection.
  9. The results from the EAServer function are returned to PowerDynamo through an ODBC or Open Client connection.
  10. PowerDynamo passes the results, in HTML format, back to the Web server.
  11. The results are passed back to the client through an HTTP connection.

Notes

A Web author may embed calls to EAServer components within a Dynamo script or template. The Dynamo script executes in the regular manner until the call to the EAServer component is encountered. At this point, a connection (through PowerDynamo) is made to the EAServer, the appropriate method will be executed and the results are returned to PowerDynamo. PowerDynamo processes the information and returns pure HTML.

 


Copyright © 2001 Sybase, Inc. All rights reserved.