Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services



Similar documents
Tutorial on Building a web Application with Jdeveloper using EJB, JPA and Java Server Faces By Phaninder Surapaneni

Building and Using Web Services With JDeveloper 11g

Developing Rich Web Applications with Oracle ADF and Oracle WebCenter Portal

Query JD Edwards EnterpriseOne Customer Credit using Oracle BPEL Process Manager

Publishing, Consuming, Deploying and Testing Web Services

Oracle Technology Network Virtual Developer Day. Developing RIA Web Applications with Oracle ADF

Application. 1.1 About This Tutorial Tutorial Requirements Provided Files

Developing Web and Mobile Dashboards with Oracle ADF

DEVELOPING CONTRACT - DRIVEN WEB SERVICES USING JDEVELOPER. The purpose of this tutorial is to develop a java web service using a top-down approach.

Tutorial on Operations on Database using JDeveloper

Oracle Service Bus Examples and Tutorials

IBM Operational Decision Manager Version 8 Release 5. Getting Started with Business Rules

Outlook Profile Setup Guide Exchange 2010 Quick Start and Detailed Instructions

ADF Code Corner. 92. Caching ADF Web Service results for in-memory filtering. Abstract: twitter.com/adfcodecorner

ADFS Integration Guidelines

How to set up Outlook Anywhere on your home system

ORACLE BUSINESS INTELLIGENCE WORKSHOP

Egnyte Single Sign-On (SSO) Configuration for Active Directory Federation Services (ADFS)

Have you ever done something the long way and then

OUTLOOK ANYWHERE CONNECTION GUIDE FOR USERS OF OUTLOOK 2010

1. Open the preferences screen by opening the Mail menu and selecting Preferences...

SQL Server 2005: Report Builder

Oracle Universal Content Management

Building Java Servlets with Oracle JDeveloper

Oracle Business Intelligence ADF Custom Visualizations and Integration. An Oracle White Paper November 2012

Oracle Application Development Framework Overview

Exchange Outlook Profile/POP/IMAP/SMTP Setup Guide

BusinessObjects Enterprise XI Release 2

HANDS-ON PRACTICE: DEPLOY AN APPLICATION

JBoss SOAP Web Services User Guide. Version: M5

Oracle Fusion Middleware

client configuration guide. Business

IBM BPM V8.5 Standard Consistent Document Managment

1. Open the preferences screen by opening the Mail menu and selecting Preferences...

Tutorial: BlackBerry Object API Application Development. Sybase Unwired Platform 2.2 SP04

Tutorial: Mobile Business Object Development. Sybase Unwired Platform 2.2 SP02

An Oracle White Paper September Oracle Team Productivity Center

Tutorial: Mobile Business Object Development. SAP Mobile Platform 2.3

Step-by-Step guide for SSO from MS Sharepoint 2010 to SAP EP 7.0x

Veritas Cluster Server Database Agent for Microsoft SQL Configuration Guide

Update Instructions

The Oracle Fusion Development Platform

How to Set Up Outlook 2007 and Outlook 2010 for Hosted Microsoft Exchange if the Program is Already Installed

Delegated Administration Quick Start

Using Windows Task Scheduler instead of the Backup Express Scheduler

Moving the TRITON Reporting Databases

This tutorial provides detailed instructions to help you download and configure Internet Explorer 6.0 for use with Web Commerce application.

Cloud Administration Guide for Service Cloud. August 2015 E

Exchange Outlook Profile/POP/IMAP/SMTP Setup Guide

Workshop for WebLogic introduces new tools in support of Java EE 5.0 standards. The support for Java EE5 includes the following technologies:

Windows XP Exchange Client Installation Instructions

Developing SQL and PL/SQL with JDeveloper

Tutorial: Mobile Business Object Development. SAP Mobile Platform 2.3 SP02

Scribe Online Integration Services (IS) Tutorial

Don t get it right, just get it written.

Erie 1 BOCES/WNYRIC. Secure File Transfer. Upload/Download Wizard

CA Nimsoft Service Desk

This presentation is for informational purposes only and may not be incorporated into a contract or agreement.

Getting Started with the Aloha Community Template for Salesforce Identity

EMC Documentum Business Process Suite

Colligo Manager 6.0. Offline Mode - User Guide

Update Instructions

MultiSite Manager. User Guide

Configuring Apache HTTP Server as a Reverse Proxy Server for SAS 9.3 Web Applications Deployed on Oracle WebLogic Server

DEPLOYMENT GUIDE Version 2.1. Deploying F5 with Microsoft SharePoint 2010

Walkthrough: Creating and Using an ASP.NET Web Service in Visual Web Developer

Security Assertion Markup Language (SAML) Site Manager Setup

Team Foundation Server 2012 Installation Guide

Defender EAP Agent Installation and Configuration Guide

Tutorial: Android Object API Application Development. SAP Mobile Platform 2.3 SP02

1. Tutorial Overview

1. Open Thunderbird. If the Import Wizard window opens, select Don t import anything and click Next and go to step 3.

How To Load Data Into An Org Database Cloud Service - Multitenant Edition

Implementing a SAS Metadata Server Configuration for Use with SAS Enterprise Guide

Oracle Business Intelligence 11g OPN Advanced Workshop

Deploying the BIG-IP System with Oracle E-Business Suite 11i

Install and Configure Oracle Outlook Connector

Instructions for Configuring a SAS Metadata Server for Use with JMP Clinical

C-more Remote Access with Apple ipad or iphone Tutorial

Technical Note. Configuring Outlook Web Access with Secure WebMail Proxy for eprism

DEPLOYMENT GUIDE Version 1.2. Deploying the BIG-IP System v10 with Microsoft IIS 7.0 and 7.5

Configuring IBM HTTP Server as a Reverse Proxy Server for SAS 9.3 Web Applications Deployed on IBM WebSphere Application Server

DESKTOP CLIENT CONFIGURATION GUIDE BUSINESS

InformationNOW Upgrading to Microsoft SQL Server 2008

How to connect to VUWiFi

ORACLE BUSINESS INTELLIGENCE WORKSHOP

HDAccess Administrators User Manual. Help Desk Authority 9.0

Dell SupportAssist Version 2.0 for Dell OpenManage Essentials Quick Start Guide

Configuration Task 3: (Optional) As part of configuration, you can deploy rules. For more information, see "Deploy Inbox Rules" below.

Configuring Outlook for Windows to use your Exchange

Perceptive Connector for Infor Lawson AP Invoice Automation

Table of Contents. 1. Content Approval...1 EVALUATION COPY

MadCap Software. Upgrading Guide. Pulse

Managing Software Updates with System Center 2012 R2 Configuration Manager

Microsoft OCS with IPC-R: SIP (M)TLS Trunking. directpacket Product Supplement

Tutorial: Android Object API Application Development. SAP Mobile Platform 2.3

Tutorial: Building a Web Application with Struts

WHITE PAPER Citrix Secure Gateway Startup Guide

Crystal Reports Installation Guide

Configuring Network Load Balancing with Cerberus FTP Server

Transcription:

Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services Tutorial By: Maneesh Agarwal,Venugopalan Sreedharan Agile PLM Development October 2009

CONTENTS Chapter 1 Overview... 3 About this Tutorial...4 Time to Complete...4 Chapter 2 Getting Started... 5 Understanding WSDL Files...5 New Topic (14)...6 Preparing the Required Environment...6 Chapter 3 New Topic (14)... 7 Building the Web Service Application...7 Building the Web Service Proxy...9 Building the Web Service CollaborationPOJO... 12 Creating a data control for the POJO... 16 Designing the Web Page... 16 Creating Navigation Cases... 17 Designing the Index Page... 18 Designing the StatusInfo Page... 20 Chapter 4 Testing the Web Application... 22 Procedures... 22 Chapter 5 Concluding Remarks... 26 Tutorial Objectives... 26 Other Sources of Information... 26 Chapter 1 Overview This chapter includes the following: About this Tutorial... 4 Time to Complete... 4 Error! No text of specified style in document. 3

Tutorial About this Tutorial In this tutorial, you will use Oracle JDeveloper 11.1.1.1.0 and ADF (Application Development Framework) components to build a customized Web application for Agile PLM. You will utilize Web services provided in Agile 93 from JSF pages to extend the supported Agile PLM functionalities. The goal of this tutorial is to demonstrate creating custom user interfaces for Agile 93 using ADF. components and Web services. Time to Complete The estimated time to complete this tutorial is 45 minutes. 4 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 2: Getting Started Chapter 2 Getting Started This chapter includes the following: Understanding WSDL Files... 5 New Topic (14)... 6 Preparing the Required Environment... 6 Understanding WSDL Files Files with the WSDL extension contain Web service interfaces expressed in the Web Service Description Language (WSDL). WSDL is a standard XML document type specified by the World Wide Web Consortium. WSDL files are used to communicate interface information between Web service producers and consumers. A WSDL file provides all the information a client application needs in order to use the Web service. A WSDL description allows a client to utilize a Web service s capabilities without knowing the implementation details of the Web service. A WSDL file contains the following information which is necessary for a client to invoke the methods of the Web service: The data types used as method parameters or return values The individual methods names and signatures (WSDL refers to methods as operations) The protocols and message formats allowed for each method The URLs used to access the Web service Error! No text of specified style in document. 5

Tutorial New Topic (14) Agile WSDL files describe Web services that are used to obtain Agile metadata, search for business objects, download attachments, and manipulate tables and perform collaboration tasks. In this tutorial you will generate the stubs for Agile Collaboration Web services and design a Web application that will invoke these services. The Web pages designed must be able to authenticate a user, query the status of any routable Agile object, and enable the end user to change the status for the given routable object. Preparing the Required Environment Complete the following tasks before starting to build the application: Install Oracle JDeveloper 11.1.1.1.0. You can download it from Oracle Technology Network (OTN) Web site http://www.oracle.com/technology/documentation/agile.html. Acquire access and a user account to Agile PLM Release 9.3 Verify the location of the WSDL files for available Web services on the Agile server. You can find a list of these services at http://<agileserver>:<port>/coreservice/services. 6 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 3: New Topic (14) Chapter 3 New Topic (14) This chapter includes the following: Building the Web Service Application... 7 Building the Web Service Proxy... 9 Building the Web Service CollaborationPOJO... 12 Creating a data control for the POJO... 16 Designing the Web Page... 16 Creating Navigation Cases... 17 Designing the Index Page... 18 Designing the StatusInfo Page... 20 Building the Web Service Application Complete the following steps to build the Web service application. 1. Open JDeveloper. 2. Select the default role when prompted for your user role at startup. 3. Expand the applications navigator and select New Application. Error! No text of specified style in document. 7

Tutorial 4. In the Create Application dialog box, enter Agile Web Services for the application name and enter oracle as the application package prefix. Now select Fusion Web Application (ADF) from the Application Template drop-down list. 5. In the Create Application dialog box, type Agile Web Services for the application name and oracle for the application package prefix. 6. Select Fusion Web Application (ADF) from the Application Template drop-down list. 7. Click Finish to complete creating of the application. 8 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 3: New Topic (14) The Application Navigator shown below will appear. Building the Web Service Proxy Use the following procedure to create a Web service proxy for Agile Collaboration services. 1. Right click on Model and then select New. Error! No text of specified style in document. 9

Tutorial The New Gallery wizard opens. 2. In New Gallery wizard, do as follows: a. Select All Technologies tab. b. In Categories pane, select Business Tier > Web Services. c. In Items pane, select Web Service Proxy. d. Click OK to proceed The Create Web Service Proxy wizard opens. 3. In Create Web Service Proxy wizard do as follows: a. Click Select Client Style and select JAX-RPC Web Logic Style in the right pane. 10 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 3: New Topic (14) b. Click Select Web Service Proxy and type the applicable URL in WSDL Document URL: field for Agile Collaboration services, for example, http://<agileserver>:<port>/coreservice/services/collaboration?wsdl, and then click Next, and JDeveloper will build the model and generate stubs for this WSDL file. c. Click Specify Default Mapping Options and Package Name: field type collaboration. and then click Next > Run against a service deployed to an external server. d. Click Next twice and then click Finish to complete creating the Web Service proxy. Error! No text of specified style in document. 11

Tutorial The Applications Navigator displays the Web Service proxy files that are generated. Building the Web Service CollaborationPOJO Agile Web services use ComplexTypes in both request and response variables. To expose these as user interface components you may create a POJO class where all the necessary fields are declared as variables with accessors. Client code to invoke the web services for getstatus and changestatus is written as methods in this class. These methods will be exposed as ADF buttons in the web pages. 1. Right click on Model, choose New, and under the category General, choose Java Class. 12 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 3: New Topic (14) 2. Type CollaborationPOJO for class name and then click OK. Error! No text of specified style in document. 13

Tutorial 3. Create two new variables username and password and then right click and select Generate accessors. 4. Declare two variables to hold the Agile class identifier and Agile object number values and call them classidentifier and objectidentifier. Similarly, declare a variable named newstatus to use while invoking the changestatus Web service. Note These are necessary to get the status of the routable object with the getstatus Web service. 5. Declare two variables for the Web service responses; one of type GetStatusResponseType and another of type ChangeStatusResponseType. 6. Generate accessors for all declared variables. 7. Write the methods getstatus and changestatus which consisting of client code using the Web service proxy to invoke the Web services. Username and password information must be set on the Web service port. Requests are formed using the necessary input values and web services are invoked on the Web service proxy porttype object. For more information on writing Agile Web service client code, refer to Agile 93 Web service manual. 14 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 3: New Topic (14) You can refer to the following sample code to test the Web service client code. For information about complex requests and responses in ADF, refer to article and its references at this site: http://www.oracle.com/technology/products/jdev/howtos/1013/wsadf/adfcomplexwstypes.html Also, JDeveloper 11g provides support for complextypes, the following article describes consumption of Agile web services using the inbuilt support for complex input parameters. Refer to article and its references at this site: Error! No text of specified style in document. 15

Tutorial http://download.oracle.com/otndocs/technology/tech/fmw4apps/agile/pdf/adf11gagile.pdf. In this tutorial however, we will restrict our discussion to the usage of POJO classes for handling complextypes. Creating a data control for the POJO To create a data control for the POJO façade, complete the following steps: 1. Right click on the POJO class CollaborationPOJO. 2. Click on Create Data Control. The data control for CollaborationPOJO listed in the Data Controls pane appears. Designing the Web Page To design the Web pages of the application, use a JSF page flow and configuration file as shown below. 1. Right click on the ViewController project and click New. 2. Under the Web Tier category, select JSF and choose JSF Page Flow and Configuration. 16 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 3: New Topic (14) This will create the file faces-config.xml to configure the Web pages. 3. Select and drag the JSF Page component from the components palette to the faces-config diagram; rename the JSF page and add two more pages and rename them as shown below. Creating Navigation Cases This step creates a navigation case from the first JSF page to the second. To do this, do as follows: 1. Drag the JSF Navigation Case component onto the first JSF page and draw a line onto the second. Rename the case from the default label success to getstatus. Error! No text of specified style in document. 17

Tutorial 2. Similarly, add three more navigation cases as shown below: Designing the Index Page 1. Double click on JSF pages in the faces-config diagram view. 2. Double click on index.jsfx. 3. Choose Oracle Three Column Layout for the initial page layout. 4. Expand the Page implementation node and make sure Do not automatically expose UI components in a managed bean is selected. 5. Expand the CollaboartionPOJO node in the DataControls panel and drag the username field to the left pane of the page. 18 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 3: New Topic (14) 6. Select Create > Texts > ADF Input Text w / Label. 7. Drag the password field in the left pane and drag classidentifier and objectidentifier onto the middle pane. 8. Change the password input text s appearance to secret using the property inspector. 9. Drag the operation getstatus onto the middle pane and select Create > Methods > ADF (button). This operation is bound to the method in the POJO class for invoking the getstatus Web service that queries the status of any Agile PLM routable object. 10. In property inspector, for the button, edit the Action value and choose getstatus which is the navigation case you defined in faces-config.xml. Error! No text of specified style in document. 19

Tutorial When you are done, your page should now look like this. Designing the StatusInfo Page This is similar to the previous step. Go back to faces-config.xml and double click on StatusInfo.jspx. Define this page as you did the index page. Now we are ready to display the results from the Web service operation. 1. Expand the node getstatusresponse in the Data Controls pane. 2. Expand StatusCode and drag the value element to the right pane of the Web page. This value indicates whether the Web service call executed successfully or not. 3. IngetStatusResponse, select and drag statusresponse to the middle panel and choose Create- >Tables->ADF Read Only Table. 20 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 3: New Topic (14) 4. Accept the default values as shown below and click OK. 5. Similarly, drop the element exception under Exceptions node and the element warning under Warnings node as read only tables. These will provide warnings or exceptions that are encountered while invoking the Web service. 6. Drag a button from the component palette and label it Back. 7. In property inspector, edit the Action property and in Navigation case, select back defined earlier. Error! No text of specified style in document. 21

Tutorial Chapter 4 Testing the Web Application This chapter includes the following: Procedures... 22 Procedures The test involves checking the status of an ECO called C00001. To test the Web application, do as follow: 1. Click on Save All. 2. Open index.jspx, right click and choose Run. 3. This starts the Web Logic server, if it is not already running and will deploy your application before automatically bringing up the Web page for testing. Our index page now looks like this: 4. Type your Agile username and password and an ECO called C00001. 5. Click getstatus to query for the status of ECO C00001. 22 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 4: Testing the Web Application The status information page displaying the information that was retrieved from the result of the Web service query appears. You can now extend this Web application to change the status of a routable Agile object. To do this, do as follows: 6. Expose the variable newstatusidentifier from CollaborationPOJO DataControls as an input on the StatusInfo JSF page. 7. Drag the operation changestatus as an ADF button and in action property choose the navigation case changestatus. The button will invoke the change status Web service and redirect the user to the third JSF Error! No text of specified style in document. 23

Tutorial page ChangedStatus.jsfx. 8. After defining ChangedStatus.jsfx, drag the status code element as an output text component to the web page. Using this value the end user can determine whether the object was successfully routed to a new state. After these changes the web page would look like this: 24 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 4: Testing the Web Application If the change status Web service succeeds, then the following page appears. Error! No text of specified style in document. 25

Tutorial Chapter 5 Concluding Remarks This chapter includes the following: Tutorial Objectives... 26 Other Sources of Information... 26 In this tutorial you created a Web application to query and change the status of Agile routable objects using the capabilities provided by Agile 93 Web Services. In this process, you learned to: Build the data model for Agile web services from a WSDL file Expose the necessary Web services through a POJO facade for which you created the data controls Create Page Flows and navigation cases for Index, Status Info,and Change Status Web pages Run the JSF pages and utilize Agile Web Services Tutorial Objectives In this tutorial you created a Web application to query and change the status of Agile routable objects using the capabilities provided by Agile 93 Web Services. In this process, you learned to: Build the data model for Agile web services from a WSDL file Expose the necessary Web services through a POJO facade for which you created the data controls Create Page Flows and navigation cases for Index, Status Info,and Change Status Web pages Run the JSF pages and utilize Agile Web Services Other Sources of Information To learn more about Oracle ADF and JDeveloper, can refer to: The Oracle Application Developer Framework home page on Oracle Technology Network (OTN) Web site http://www.oracle.com/technology/documentation/agile.html. 26 Building an Agile PLM Web Application with JDeveloper and Agile 93 Web Services

Chapter 5: Concluding Remarks The JDeveloper home page at http://www.oracle.com/technology/products/jdev/index.html on OTN http://www.oracle.com/technology/documentation/agile.html. Oracle JDeveloper is a free integrated development environment with end-to-end support for modeling, developing, debugging, optimizing, and deploying Java applications and Web services. Error! No text of specified style in document. 27