F8:The Progress AppServer

advertisement
Exchange
2001
PROGRESS WORLDWIDE
F8: Progress AppServer
Pat Bonser
Technical Marketing Manager
Progress Software
Agenda







What is the Progress AppServer ?
Architecture
Components
Running remote procedures
Operating Modes
Open Client
Summary
Exchange 2001, Washington, DC, USA
2
© 2001, Progress Software Corporation
Progress AppServer




Foundation for Progress’ distributed
computing strategy
The framework for developing and
deploying 4GL procedures as distributed
application components
Business logic encapsulated into
components that can be deployed across
the enterprise
RPC for the 4GL
Exchange 2001, Washington, DC, USA
3
© 2001, Progress Software Corporation
Progress AppServer
Character
GUI
Distributed
Application
Exchange 2001, Washington, DC, USA
4
© 2001, Progress Software Corporation
Progress AppServer Architecture
Clients
AppServer
GUI
Exchange 2001, Washington, DC, USA
NameServer
Character
Application
Broker
5
Application Servers
4GL
Business
Logic
© 2001, Progress Software Corporation
Progress AppServer Components





NameServer
Application Broker
Application Server Process
AppServer Internet Adapter - AIA & AIA/S
Clients
– Progress

GUI, Character, WebClient, WebSpeed Agents
– Open Clients

Java, ActiveX
Exchange 2001, Washington, DC, USA
6
© 2001, Progress Software Corporation
NameServer

Location Transparency
– Client requests an Application Service not a
connection to a specific AppServer

Load Balancing
– Multiple AppServers can register to support
the same Application Service
– Connection requests can be balanced across
AppServers
– Weight factor determines distribution
– A “hot stand-by” using a weight factor of 0
Exchange 2001, Washington, DC, USA
7
© 2001, Progress Software Corporation
NameServer




AppServer registers with NameServer the
Application Service(s) it supports
Client requests an Application Service from
the NameServer
Communication with NameServer UDP
Fault-tolerance for NameServer
– NameServer Replication
– NameServer Neighbors
Application Service – logical name, eg:
Inventory, Parts, Account, com.progress.orders
Exchange 2001, Washington, DC, USA
8
© 2001, Progress Software Corporation
Application Broker

Typically started at system startup-time

Manages pools of re-usable application
server processes

Manages client requests for 4GL
procedure execution
Exchange 2001, Washington, DC, USA
9
© 2001, Progress Software Corporation
Application Server Process

Executes Progress 4GL procedures

Application Server Processes are reused
– Determined by AppServer Operating Mode
Exchange 2001, Washington, DC, USA
10
© 2001, Progress Software Corporation
AppServer Internet Adapter




Extends the AppServer to the Internet
HTTP & HTTPS Tunneling
Java Servlet
ALL Progress 4GL Clients
Web Server
INTERNET
JSE
AppServer
AIA
Exchange 2001, Washington, DC, USA
11
© 2001, Progress Software Corporation
Running Remote Procedures
AppServer
1. Create server handle
2. Connect to AppServer
4GL Business Logic
procedure b
procedure a
3. RUN procedures
procedured
procedurec
4. Disconnect
5. Delete server handle
Exchange 2001, Washington, DC, USA
12
© 2001, Progress Software Corporation
Running Remote Procedures
4GL Client





CREATE SERVER handle
handle:CONNECT(connection_parameters,
userid,
password,
appserver_info)
RUN procedureA ON SERVER handle
handle:DISCONNECT()
DELETE OBJECT handle
Exchange 2001, Washington, DC, USA
13
© 2001, Progress Software Corporation
Running Remote Procedures
Connection Parameters

-H
IP address or TCP/IP host name of NameServer

-S
Port Number or UDP service name of NameServer

-AppService
Application Service registered with NameServer
or
 -URL
To connect to AppServer using the AIA or AIA/S
Exchange 2001, Washington, DC, USA
14
© 2001, Progress Software Corporation
Running Remote Procedures
4GL Client
DEFINE VARIABLE hdl AS HANDLE.
DEFINE VARIABLE ret AS LOGICAL.
DEFINE VARIABLE account-number AS INTEGER.
CREATE SERVER hdl.
ret = hdl:CONNECT(“-S 5555 -H zeus -AppService Account”).
RUN AccountInfo.p
ON SERVER hdl
(INPUT account-number).
ret = hdl:DISCONNECT().
DELETE OBJECT hdl.
Exchange 2001, Washington, DC, USA
15
© 2001, Progress Software Corporation
Asynchronous Calls
Server1
Server2
Standard AppServer Calls
are synchronous, blocking
the client during active call
. . . . . . . .Time
Client
.........
RUN proc ON server ASYNCHRONOUS. . . . . . . .
Exchange 2001, Washington, DC, USA
With Asynchronous calls
the client can make multiple
calls to multiple servers
16
© 2001, Progress Software Corporation
Connecting to an AppServer
How does it work?
Host=Gemini
Port=5162
AS=Inventory
NameServer
Client
Host=zeus
Port=3097
Connect
Host=zeus
Port=3097
AppServer
handle:CONNECT(“-H Gemini -S 5162 -AppService Inventory”)
Exchange 2001, Washington, DC, USA
17
© 2001, Progress Software Corporation
Running Remote Procedures
How does it work?
Host=Gemini
Port=5162
AS=Inventory
NameServer
Host=zeus
Port=3097
Host=zeus
Port=3097
Procedure foo
Client
Run
Connect
AppServer
RUN foo.r on SERVER handle
Exchange 2001, Washington, DC, USA
18
© 2001, Progress Software Corporation
Replicated AppServers
Host=zeus
Port=3097
Weight=70
How does it work?
AppServer
Client
Host=Gemini
Port=5162
AS=Inventory
NameServer
zeus, 3097, 70
herta, 7394, 30
Client
AppServer
handle:CONNECT(“-H Gemini -S 5162 -AppService Inventory”)
Exchange 2001, Washington, DC, USA
19
Host=herta
Port=7394
Weight=30
© 2001, Progress Software Corporation
Replicated NameServers
How does it work?
NameServer
Host=172.20.0.7
Port=5162
Host=zeus
Port=3097
AS=Inventory
Host=zeus
Port=3097
Client
AppServer
Connect & Run
AS=Inventory
NameServer.NS1
portNumber=5162
hostName=172.20.255.255
Host=zeus
Port=3097
NameServer
Host=172.20.6.4
Port=5162
Connect(“-H 172.20.255.255 -S 5162 -AppService Inventory”)
Exchange 2001, Washington, DC, USA
20
© 2001, Progress Software Corporation
AppServer Operating Modes



Specified when an AppServer is
configured
Determines how client requests are
dispatched to individual Application
Server processes
Will have significant impact on the design
and performance of your application
Exchange 2001, Washington, DC, USA
21
© 2001, Progress Software Corporation
AppServer Operating Modes

State-Aware
– One client per application server process
– Application server session objects maintained
across connections

State-Reset
– One client per application server process
– Application server session automatically reset

Stateless
– Many clients per application server process
– Context must be managed externally
Exchange 2001, Washington, DC, USA
22
© 2001, Progress Software Corporation
Choosing an Operating Mode
State-Aware


State-Reset
Stateless
Design-time Decision
Factors Affecting Decision
– Design Complexity
– Resource Consumption
– Performance


Request Throughput
Response Time
– Application Context
Exchange 2001, Washington, DC, USA
23
© 2001, Progress Software Corporation
Resource Considerations
System Resources
State-reset
State-aware
Stateless
(Bound/Unbound)
Stateless
Throughput
Exchange 2001, Washington, DC, USA
24
© 2001, Progress Software Corporation
Resource Considerations
State-reset
Response Time
State-aware
Stateless
(Bound/Unbound)
Stateless
Development Costs
Exchange 2001, Washington, DC, USA
25
© 2001, Progress Software Corporation
Open Client access to Progress
GUI
AppServer
4GL Business Logic
Character
P
R
O
X
Y
P
R
O
X
Y
Exchange 2001, Washington, DC, USA
26
© 2001, Progress Software Corporation
Open Client Interface




Maps 4GL concepts to Open Client concepts
Server handle is an application object
Persistent procedure handle is a procedure
object
Non-persistent procedures, internal
procedures and user defined functions map
to object methods
Exchange 2001, Washington, DC, USA
27
© 2001, Progress Software Corporation
Open Client Model
ProcObject:
App Object: Account
AcctInfo
AcctInfo.p
Proc getPaymentsInfo
add.p
remove.p update.p
Exchange 2001, Washington, DC, USA
28
Function getStartDate
© 2001, Progress Software Corporation
Proxy Generation
4GL
.r files
Business logic
ProxyGen
Proxies
Automation Object (DLL)
Java classes
Exchange 2001, Washington, DC, USA
29
© 2001, Progress Software Corporation
4GL Example to be run by Open Client
/* AccountInfo.p Procedure */
DEFINE INPUT PARAM account-num AS INTEGER.
/* … AccountInfo.p code … */
/* AccountInfo.p Internal Procedures */
/* getPaymentsInfo returns payment records. */
PROCEDURE getPaymentsInfo:
DEFINE INPUT PARAM
from-date AS DATE.
DEFINE INPUT PARAM TABLE FOR
payee-list.
DEFINE OUTPUT PARAM payments-num AS INTEGER.
DEFINE OUTPUT PARAM TABLE FOR payments-info.
/* ... getPaymentsInfo Code ... */
END PROCEDURE.
Exchange 2001, Washington, DC, USA
30
© 2001, Progress Software Corporation
Java Client access to 4GL Example
Account account = new Account(“AppServer://zeus:5162”,
“wilner”,“futureproof”,null);
AccountInfo info = account.createPO_AccountInfo(777);
java.util.Date
fromDate;
java.sql.ResultSet payeeList;
COM.progress.o4gl.IntegerHolder
paymentsNum;
COM.progress.o4gl.ResultSetHolder paymentsInfo;
info.getPaymentsInfo(fromDate,
payeeList,
paymentsNum,
paymentsInfo);
Exchange 2001, Washington, DC, USA
31
© 2001, Progress Software Corporation
VB Client access to 4GL Example
Dim acct As AccountLib.CAccount
Set acct = new CAccount
acct.OC_Connect("AppServer://zeus:5162", "wilner", "futureproof")
Dim info As AccountLib.CPO_AccountInfo
set info = acct.createPO_AcctInfo(777)
Dim payeeList As ADODB.Recordset
Dim payees As ProO4glActiveXLib.CProTempTable
Dim payments As ProO4glActiveXLib.CProTempTable
Set payees = new CProTempTable ' input Temp-Table
Set payments = new CProTempTable ' output Temp-Table
payees.DataSource = payeeList
Dim paymentsNum as Long
Dim fromDate as double
Call info.getPaymentsInfo(fromDate, payees, paymentsNum, payments)
Exchange 2001, Washington, DC, USA
32
© 2001, Progress Software Corporation
Configuration Flexibility






Multiple AppServers per machine
Multiple AppServers to support one
Application Service
NameServer on the AppServer machine
NameServer on it’s own machine
NameServer on the client machine
Multiple NameServers
Exchange 2001, Washington, DC, USA
33
© 2001, Progress Software Corporation
Scalability & Availability






Re-useable Servers
Replicated Servers
Stateless Servers
Message Queuing
Load Balancing
Location Transparency
Exchange 2001, Washington, DC, USA
34
© 2001, Progress Software Corporation
Summary
AppServer in a nutshell!

Open Interfaces

Highly Scalable

Location transparency, fault-tolerance,
load balancing

Easy-to-use GUI-based configuration

“Internet-ready”
Exchange 2001, Washington, DC, USA
35
© 2001, Progress Software Corporation
Questions
Exchange 2001, Washington, DC, USA
36
© 2001, Progress Software Corporation
Download