12.11.2014 Views

web server - Borland Technical Publications

web server - Borland Technical Publications

web server - Borland Technical Publications

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Web Service providers<br />

Java:VISIBROKER provider<br />

This provider assumes that the class serving the <strong>web</strong> service is a Visibroker <strong>server</strong>.<br />

When a <strong>web</strong> service request arrives, this provider:<br />

1 Initializes the ORB.<br />

2 Locates the CORBA object using “objectName” and “locateUsing” properties.<br />

3 Invokes the specified method on the CORBA stub.<br />

The parameters are:<br />

■<br />

objectName: The name of the object. This is a mandatory parameter.<br />

■<br />

locateUsing: This parameter specifies which mechanism the provider uses to locate<br />

the object.<br />

The 3 possible values are:<br />

osagent<br />

nameservice<br />

ior<br />

The object is assumed to be in osagent. The bind() method on helper<br />

is used to locate the object. The Server object must be registered with<br />

the same osagent that the Partition is using. If poaName is also<br />

specified, objectName is located under that POA. This is the default<br />

value of the parameter.<br />

The object is assumed to be in Naming Service. The resolve()<br />

method on the root context is used to locate the object. The<br />

objectName must be the full name of the object starting from root<br />

context. For example:<br />

USA/California/SanMateo/BigAnimal<br />

The VisiBroker <strong>server</strong> object must be registered with the same<br />

name service that the Partition is using. Typically, a Partition starts<br />

a name service with the name “namingService”. For a <strong>server</strong> to<br />

use the same name service, it must be started as follows:<br />

vbj -DSVCnameroot=namingservice Server<br />

The objectName provided is assumed to be an IOR. The<br />

string_to_object() method on the ORB is used to obtain the object.<br />

The IOR can be in standard form. For example:<br />

corbaname::172.20.20.28:9999#USA/California/SanMateo/<br />

BigAnimal<br />

IOR:xxx<br />

corbaloc::172.20.20.28:30303,:172.20.20.29:30304/MyObject<br />

■<br />

■<br />

className: The name of the class that is loaded when a request arrives on this<br />

service. Typically, this is the name of the CORBA class generated and based on the<br />

IDL. The VisiBroker client stubs, including this class, must be present in the WAR.<br />

allowedMethods: The methods that are allowed to be invoked on this class. The<br />

CORBA object can have more methods than listed here; the methods listed here are<br />

available for remote invocation.<br />

■<br />

poaName: The name of the POA that hosts the CORBA object. This parameter is<br />

relevant only when the locateUsing parameter value is osagent.<br />

Example:<br />

<br />

<br />

<br />

<br />

<br />

<br />

Chapter 9: <strong>Borland</strong> Enterprise Server Web Services 77

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!