The first requirement for inter-portlet and portlet-to-eclipse communication is to define the WSDL file that declares the actions and properties of the portlets or eclipse components with the Property Broker. The basic WSDL for the property broker is identical to that of Portal. The namespace and bindings should all be consistent with any WSDL used to define properties and actions on Portal.
The WSDL file should be contributed to the Lotus® Expeditor platform using an eclipse extension. This extension is registered with the broker.
To wire two portlets or a portlet and an eclipse component, perform the following procedure:
- Select a Client Services Portlet project or Client Services plug-in project you wish to add the WSDL file to.
- Right click the Client Services portlet project and select New > Other > Client Services > Wiring Properties to create a new WSDL file. Create the new WSDL file in the Web Content directory of the project.
- Select Next.
- Enter the name of the Client Services project you wish to add the WSDL file to.
- Select Next.
- Set the target namespace to http://www.ibm.com/wps/c2a. Use defaults for all other options.
- Select Finish.
- Right click the WSDL file and select Open With > Wiring Properties to edit the new WSDL file. Things to remember when editing the WSDL file:
Add the required actions and properties to the WSDL file and save the WSDL file.
- <wsdl:types> elements are registered with the Property Broker and mapped to actions
- <wsdl:message> elements must reference a valid <wsdl:type>
- The name of the <wsdl:portType> element will be used to map the action to the operation
- <wsdl:binding> elements are used to define binding of the action to its input and output parameters. The <input> and <output> elements are used to link the action to a <wsdl:type>
- The name of the <portlet:action> element is registered with the Property Broker. Wire definitions should reference this name (see below).
To register the WSDL file with the Property Broker, perform the following procedure:
- Select the Client Services Portlet project that contains the WSDL file you want to register with the Property Broker.
- Right click the portlet.xml descriptor and select Open With > XML Editor.
- Add the location of the WSDL as a portlet preference. The preference name must be com.ibm.portal.propertybroker.wsdllocation, the value of the preference must be a valid location in the portlet project. An example preference definition would look like this:
Parent topic: Portlet intercommunication: XPD621