Upload
zeeshan-baig
View
10.421
Download
1
Embed Size (px)
Citation preview
Working with Portlets in Oracle ADF & Webcenter
Presenter: Zeeshan Baigwww.baigzeeshan.com
www.youtube.com/baigsorcl
1Session # 288
A little about me….• Currently working as Senior Architect Developer at Northwestern
Memorial Hospital in Chicago.• 12+ years of experience in Oracle Development tools (Database,
Forms, APEX, ADF, Fusion)• Oracle ACE, OCP DBA certified in 8, 8i and 10g• Technical blog on ADF and other fusion technologies at
www.baigzeeshan.com• YouTube channel http://youtube.com/baigsorcl
Disclaimer: The views expressed are my own and does not affiliates with my employer
Images used in this presentation courtesy of Google images and Oracle Documentation
2Session # 288
Agenda
• ADF & Webcenter Overview
• What is Portlet?
• Portlets Producer Types and Modes
• ADF Task flows v/s Portlets
• Developing Portlets in ADF
• Testing and Deploying Portlets
• Consuming Portlets in Webcenter Portal and Spaces
• Portlet Communication
• Tips & Guidelines
• Demo
• Q & A 3Session # 288
Survey
• How many people are familiar with Java?
• How many people are working with
Oracle ADF OR WebCenter?
• How many people have worked with Portlets?
4Session # 288
ADF & WebcenterWhat is ADF?
End to end framework builds on JEE standard platform to develop Web 2.0 Applications
What is Webcenter?
Extensional framework builds on top of ADF to develop Enterprise 2.0 portals with features like Portlets, RSS, Discussion forums and Content management
What is Jdeveloper?
A free integrated tool to build Java-SOA based applications
Session # 288 5
Things to do
• Download and Install Oracle database i.e. Oracle XE
• Download and Install Oracle Jdeveloper version 11.1.1.5 (PS4)
• Download and Install Oracle Webcenter Extensions for Jdeveloper
Session # 288 6
What is Portlet?
• As per Wikipedia
"Portlets are pluggable user interface software components
that are managed and displayed in a web portal."
• Reusable component visible on page
• Draws content from different sources
• Often compare to web-services and ADF task flows
• Can be local or remotely deployed
• Can display excerpts from other sites
• May or may not be rendered in in-line IFRAME
• Can display elements of HTML, formatted text, images
7Session # 288
Portlets
8Session # 288
Portlet Producers TypesWorks as a communication link between Portal and Portlets
WSRP Producer
Uses WSDL, allows any standard web-based application to work as portlet.
PDK-Java Producer
Uses Industry standards like XML, SOAP, HTTP.
Portal-Tools Producer
Allows to create/consume portlets on Portal without known complex programming
9Session # 288
Portlets Modes
VIEW Defines how portlet will be visible on page. All portlets must have View mode.
EDIT Allow authorized user to personalize portlet e.g. Title, appearance, content
EDIT – DEFAULTS
Allow to change system-level personalization on the portlet
HELP Allow to display information about functionality of the portlet
ABOUT Display information like version, copyright, contact author
10Session # 288
Task Flows v/s Portlets
Local Task Flow Remote Task Flow ADF Based PortletUse same Skin as consumer portal
Use its own skin. opens in pop or different window
Renders in iFrames uses its own skin
Support Transactions No Support for Transactions No Support for TransactionsInteraction between task flows via Contextual events, Input output parameters
Input output parameters inter-portlet communication
Deployed with consumer app Deployed separately Deployed separatelyFull ADF / Webcenter security Requires Single Sign-on WS-Security with OWSM is
used for authentication
11Session # 288
Portlet Types
• JSF Portlets• Programmable Portlets
• Standard Java Portlet• PDK-Java Portlet
• Web clipping• Omni Portlet
12Session # 288
JSF Portlets
• Oracle JSF Portlet Bridge allows to convert existing JSF applications into Portlets
• Same code for both portlets and app
• Right click Task flow or Page and choose “Create Portlet Entry”
• File portlet.xml file contains all metadata
13Session # 288
Programmable Portlets
• Standard based JSR 286 Portlets uses WSRP and WSDL
• PDK Java Portlets uses standard technologies
• Ideal for Integration with other apps
• Usually Deployed as WAR
14Session # 288
Web Clipping
• Clips a complete or section of web page as a portlet
• No Coding experience required
• Leverage single sign-on solution with sites requires authentication
• Some limitations exists
15Session # 288
Omni-Portlet
• Allow to add portlet to your application at design time, and customize at runtime.
• Supports many Data sources
including SQL, XML, web services, spreadsheets, and web pages.
• Supports different layouts like tables
and charts
• Allows personalization16Session # 288
Testing & Deployment
• Test in Integrated Weblogic Server
• Deploy to Weblogic server• Create WAR deployment description
• Right click portlet and create WAR file
OR
• Deploy directly to Application server
17Session # 288
Consuming Portlets
In Webcenter Portal
• Get portlet WSDL or Provider URL end- point
• Create Connection in Resource Palette or Webcenter Portal application to register the portlet
• Drag and Drop the Portlet from connection to JSF Page
• Set necessary Portlet tags and parameters
18Session # 288
Consuming PortletsIn Webcenter Spaces
• Get portlet WSDL or Provider URL end-point
• Open Enterprise Manager Fusion middleware Control
• Register Portlet with Webcenter Spaces
• Edit Webcenter spaces JSF page in Composer mode
• Add Portlet from Resource catalog
• Enter portlet parameters and Save19Session # 288
Portlets Communication• Wiring Portlets at Design Time
– Edit Page Binding for Portlet 2– Set source of parameter as source of Portlet 1– Set Partial triggers
• Wiring Portlets at Runtime– Log in as Administrator on Portal– Edit the page and go to Portlet properties– Use EL Expression to set the parameter values– Set partial triggers to portlet Id
• Contextual Wiring of Portlets using Events– Uses payLoad instead of parameter values– Set payLoad values at Event tab of portlet properties
20Session # 288
Tips & Guidelines
• Use Standard HTML and CSS
• Keep content concise
• Test in different browsers with window resizing behavior
• Never use JavaScript to do redirect inside Portlet. Open a new browser window instead
• Pop-ups, Input date, Input color are not supported inside ADF based portlet
• Use database persistence store in web.xml specially in cluster environment
• Access using HTTP server instead of direct link to WLS
21Session # 288
DEMO
22Session # 288
Thank you
23Session # 288
Congratulations!! You are now Portlet Certified…
24Session # 288
My Contact
BLOG
http://baigzeeshan.com
YouTube Channel
http://youtube.com/baigsorcl
LinkedIn:
http://www.linkedin.com/in/baigzeeshan
[email protected] # 288 25