Beruflich Dokumente
Kultur Dokumente
with
IBM WebSphere Portlet Factory
Ruth Seltzer
Senior Engineering Manager
IBM WebSphere Portlet Factory
Westford, MA
speakers and reflect their own views. They are provided for informational purposes only,
and are neither intended to, nor shall have the effect of being, legal or other guidance or
advice to any participant. While efforts were made to verify the completeness and
accuracy of the information contained in this presentation, it is provided AS IS without
warranty of any kind, express or implied. IBM shall not be responsible for any damages
arising out of the use of, or otherwise related to, this presentation or any other materials.
Nothing contained in this presentation is intended to, nor shall have the effect of, creating
any warranties or representations from IBM or its suppliers or licensors, or altering the
terms and conditions of the applicable license agreement governing the use of IBM
software.
References in this presentation to IBM products, programs, or services do not imply that
they will be available in all countries in which IBM operates. Product release dates and/or
capabilities referenced in this presentation may change at any time at IBMs sole
discretion based on market opportunities or other factors, and are not intended to be a
commitment to future product or feature availability in any way. Nothing contained in
these materials is intended to, nor shall have the effect of, stating or implying that any
activities undertaken by you will result in any specific sales, revenue growth or other
results.
IBM, the IBM logo, Lotus, Domino, WebSphere, Workplace and Lotusphere are trademarks
of International Business Machines Corporation in the United States, other countries, or
both.
Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United
States, other countries, or both.
Microsoft and Windows are trademarks of Microsoft Corporation in the United States, other
countries, or both.
Automation
Change
Reuse
Builder
An adaptive, reusable
component that
generates Java,
XML and JSP for
specific portlet
functionality
Profile
A set of parameters
that vary Builder inputs
to dynamically
generate unique
versions of the portlet
Model
A container of Builders
SQL Call
SQL Call
Service Operation
Service Operation
Service Definition
Service Consumer
RDB
Use data access builder (SQL, SAP, Domino, etc.) for back end access
Use Service Definition and Service Operation builders to create service
Can include multiple operations, data transformation, and custom processing
Note that this service can be reused across any number of portlets
Use high-level builder to create initial presentation based on service inputs and results:
Use builder such as View & Form
Forms and views are automatically generated from the schema by the Page Automation
capabilities
Fields are automatically laid out using customizable rules
Page Automation adapts automatically to schema or service changes
readDocument()
updateDocument()
Domino
Database
getEmployeesByDept()
getEmployeeRecord()
updateEmployeeRecord()
employeesGetEmployeesByDept()
employeesGetEmployeeRecord()
employeesUpdateEmployeeRecord()
Schemas
Data Service metadata that identifies the variables and methods for access
operations
Code for executing back end function
backends which are not supported out of the box. See a sample at
http://www.ibm.com/developerworks/websphere/zones/portal/portl
etfactory/samples/createbldrs.html for more information
Service Operation
Service Operation
Service Operation
Service
Mapping
Registry
Service Definition
Service Consumer
Schemas
Variables with
captured stub
data
Service Operation
methods
SAP
Debugging Techniques
Debugging Techniques
Look for builder errors and warning messages in Designer
Disable builders to simplify a model and isolate the problem
Use System.out.println in Action List or Java code
Use Java-level debugging
Can single-step and set breakpoints in generated or other code
Uses the remote Java debugging capabilities of Eclipse
See product help for details of how to set this up
Run with system tracing to see exactly what actions get executed
Look at generated code/pages
Performance
Lack of caching
Regen Profiling
For Edit mode in Portal, try to use execution profiling (specified in Profile
Set Entry). This avoids generating many different WebApps based on
personalization values
Server stats
A log file that periodically captures statistics about usage and
performance on a running server
See the WEB-INF/logs/serverStats.txt file in deployed WAR
Captures numerous statistics, such as request actions and their
latency and requests to external systems
http://www.ibm.com/developerworks/websphere/zones/portal/
portletfactory/proddoc.html for more information
Builder
Service Definition
settings
Add an operation to a service
Service Operation
testing a service
builder
Builder
Databases
SQL Call
Lotus Domino
Microsoft Excel
Excel Import
Java class
PeopleSoft
SAP
Siebel
Web Service
XML Data
Builder
Variable
schemas
manipulates IXml
Builder
Service Consumer
chart of data
Make a model available as a
Portlet Adapter
portlet
Add some structured data to a
page
Data Page
Builder
page
Create newspaper-style
Form Layout
Category View
Builder
fields
centralized control
Lookup Table
Rich Data Definition (create Lookup from RDD XML file)
Apply a lookup table to pages with Data Field Modifier,
Builder
Action List
actions
Assign a value to a variable
Add portlet-to-portlet
communication
Error Handler
Cache Control
Service Operation builder has an option to add caching
Builder
Button
Image Button
Link
submitted
Run an action when a user
Page Tabs
Builder
Visibility Setter
HTML Attribute
Localized Resource
Use Data Page Localizer or the Resource Bundle input of
Inserted Page
Text
Client JavaScript
Builder
People Awareness
Portlet Adapter
portlet
Retrieve user credentials from
WPS Credential
Target
Incremental client/server
validation as the user interacts
with a form
such as:
Form Submit Action Builder
Link Builder
Button Builder
Set the Post Action Behavior to Refresh specified page
location after running action
webAppAccess.getBackchannelActionURL(actionName,
false)
to create a URL to any model action that returns XML
That URL can be used by client code as a REST-style
service
Builder
Imported Model
Linked Model
Model Container
1/22/2007
11:00am - 12:00pm
1/22/2007
2:15pm - 3:15pm
Repeated: 5:00pm 6:00pm
1/22/2007
4:30pm - 6:15pm
1/23/2007
4:15pm - 5:15pm
1/23/2007
4:15pm - 5:15pm
1/24/2007
08:00am - 9:45am
1/24/2007
4:15pm - 5:15pm
01/24/2007
5:45pm - 6:45pm
DeveloperWorks Forums
http://www.ibm.com/developerworks/forums/wsdd_forums.jsp
http://www.ibm.com/developerworks/websphere/zones/portal/portletfa
ctory/proddoc.html
Q&A
Bonus Slides
There are several Best Practices that would not
fit into a one hour presentation. Information
about these Best Practices are available in the
following slides
Sharing functionality across models
Managing projects across a team
The problem:
Web applications need fine control of user interface for displaying and inputting data
Formatting, validation, change field behavior, etc.
This control of UI can be done using individual builders, but this results in duplicated
information across models
The solution:
Use Rich Data Definition (RDD) to control all aspects of field-level UI in a centralized,
automated way across models
RDD is attached to a schema, then generated pages automatically pick up behavior
RDD uses shared definition files
Example:
Using RDD, you can format every date field a certain way (i.e., MM/DD/YY), and use a
calendar picker when that field is editable
Imported Model
This builder works like #include in C/C++, with support for
parameterization
Used to include common elements in a set of models
Models
Shared automation
elements
Rich Data Definitions
Data Page Templates
Imported Layout Pages
Imported Models
Profile Sets
Custom Builders
Builder 1
Builder 2
Builder 3
Builder 4
Builder 1
Builder 2
Builder 3
Portlet 2
Portlet 3
Builder 1
Builder 2
Builder 3