web methods broad vision adapter tutorial v1

40
webMethods BroadVision Adapter Tutorial VERSION 1.2 1 Introduction Welcome! ..................................................................................... 2 Architecture and Components ..................................................... 3 The Global Sporting Goods Case Study ...................................... 3

Upload: api-3747380

Post on 11-Apr-2015

234 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Web Methods Broad Vision Adapter Tutorial V1

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 1

Introduct ion

Welcome!.....................................................................................2

Architecture and Components .....................................................3

The Global Sporting Goods Case Study......................................3

Page 2: Web Methods Broad Vision Adapter Tutorial V1

I n t r o d u c t i o n

2 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Welcome! The goal of this tutorial is to teach you how to install, configure, and manage the webMethods BroadVision Adapter to solve a business problem of a fictional sporting goods distributor named Sporting Goods Distributors (SGD). In this tutorial, you will assume the role of the SGD developer who solves this problem.

Currently, SGD uses a BroadVision Server to maintain its inventory and handle its purchasing processes (for example, generating purchase orders). SGD now needs to expand the breadth of its system by implementing an integration solution with its suppliers. That is, it needs to exchange business information over the Internet.

To prepare for implementing this solution, SGD has already installed the webMethods Integration Server. You will now add the BroadVision Adapter to the server so that data can flow to and from SGD’s existing system.

System Requirements You must have the following software installed before you perform the tutorial:

�� webMethods Integration Server version 3.5 or higher

�� webMethods Developer version 3.5 or higher

�� webMethods BroadVision Adapter Version 1.0 installed on a Solaris or HP-UX platform

Prerequisite Skil ls You should have a basic understanding of the following software before you use the tutorial:

�� webMethods Integration Server

�� webMethods Developer

�� JavaScript

�� BroadVision One-To-One Enterprise application

�� HTML and XML

Page 3: Web Methods Broad Vision Adapter Tutorial V1

A r c h i t e c t u r e a n d C o m p o n e n t s

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 3

Typographical Conventions

Convention Example

Procedures are described as a series of numbered steps.

1. On the Activity menu, select the File command.

Terms that identify elements, options, selections, and commands on the screen are shown in bold.

The Properties tab specifies the name of the requested service in the Service field.

Characters that you must type exactly are shown in a typewriter (courier) font.

Type: setup and then press ENTER.

Variable information that you must type based on your specific situation or environment is shown in italics.

Type: ServerDirectory\setup and then press ENTER.

Archi tecture and Components An Integration Server-BroadVision application system consists of a BroadVision server and a webMethods Integration Server with the BroadVision Adapter.

The Globa l Spor t ing Goods Case Study Sporting Goods Distributors (SGD) is a sporting goods distributor that buys goods from wholesale suppliers and sells them to retailers. In order to do this, SGD must maintain inventory and pricing information.

The Problem Currently, SGD uses a BroadVision server to maintain inventory and pricing information. This BroadVision server enables SGD employees to both add and update information.

SGD now needs to implement an integration solution with one of its suppliers—a snowboard manufacturer named Snowboard Suppliers—while still leveraging its BroadVision server architecture. That is, it needs to enable SGD and Snowboard Suppliers to send and receive business information through SGD’s BroadVision server and over the Internet.

Page 4: Web Methods Broad Vision Adapter Tutorial V1

I n t r o d u c t i o n

4 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

The Solution This tutorial provides a JavaScript page from which you (the SGD user) can execute a predefined Flow service (getCatalog) to request information about catalog items from Snowboard Suppliers. Since this service executes in your webMethods Integration Server to request information from Snowboard Supplier’s webMethods Integration Server, the request is handled by the outbound (BroadVision-to-Integration Server) adapter.

After Snowboard Suppliers returns the requested catalog item to your JavaScript page, your application must query your back-end system to find out whether the catalog item already exists in your system. To accomplish this, the application includes the BroadVision runtime service BVI_ContentManager.

If Snowboard Suppliers returns a catalog item that does not exist in your back-end system, you must be able to add it to the system. To do this, you create a Flow service named insertProduct, which is handled by the inbound (Integration Server-to-BroadVision) adapter. This service must include the following entities that we provide:

�� The CORBA interface method insert_content To implement this method, you use the inbound (Integration Server-to-BroadVision) adapter’s user interface to generate the method to produce a Flow service. This generated service represents the method.

�� The Java service insert_content_attributes

In addition, you must generate another Flow service for deleting products you added with insertProduct. The tutorial provides a CORBA interface method—delete_content_by_key—that you generate the same way you generate insert_content.

Page 5: Web Methods Broad Vision Adapter Tutorial V1

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 5

Instal l ing the Tutorial

Installing the BroadVision Adapter...............................................6

Setting up the BroadVision Adapter Tutorial................................6

Page 6: Web Methods Broad Vision Adapter Tutorial V1

I n s t a l l i n g t h e T u t o r i a l

6 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Insta l l ing the BroadVis ion Adapter and Tutor ia l To perform this tutorial, you must install the webMethods BroadVision Adapter package (BroadVision55) and the tutorial package (WmBVExample) on a Solaris, HP-UX, or Windows 2000 platform. Specifically, you must install the following:

�� The inbound (Integration Server-to-BroadVision) adapter

�� The outbound (BroadVision-to-Integration Server) adapter

�� The example package WmBVExample, which you install when you install the inbound adapter

�� The tutorial’s JavaScripts, which you install when you install the outbound adapter

For the installation procedures, see the webMethods BroadVision Adapter Installation Guide.

Set t ing up the BroadVis ion Adapter Tutor ia l The tutorial file provides the following JavaScript page and .html files that are needed to complete the exercises.

�� start.html

�� start.jsp

�� listsuppliers.jsp

�� listitems.jsp

�� verifyitem.jsp

You must copy these files into newly-created directories as follows:

To copy the example JavaScript page and .html files

Enter the following commands:

1. cd $BV1TO1_VAR/script_root

2. mkdir webmethods

3. cd webmethods

4. mkdir scripts

5. cd scripts

Page 7: Web Methods Broad Vision Adapter Tutorial V1

S e t t i n g u p t h e B r o a d V i s i o n A d a p t e r T u t o r i a l

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 7

6. cp $BV1TO1/wmbvsn55/scripts/*.jsp

7. Copy the file start.html to your web server directory. For example, if you are running an Apache server on Solaris, you would copy start.html to the apache/htdocs directory.

8. Ensure that your webMethods Integration Server, BroadVision server, and BroadVision Interaction Manager are running.

Page 8: Web Methods Broad Vision Adapter Tutorial V1
Page 9: Web Methods Broad Vision Adapter Tutorial V1

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 9

L E S S O N

Managing Al ias Sett ings

Objectives..................................................................................10

Background................................................................................10

Lesson 1 Exercise .....................................................................10

Page 10: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 1 M a n a g i n g A l i a s S e t t i n g s

10 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Ob ject ives In this lesson, you will create and test a BroadVision server alias.

Background To enable webMethods to open a session with your BroadVision server, you must provide webMethods with alias setting information—that is, a collection of configuration parameters about your BroadVision server. We provide you with the parameters for an alias.

For more information about managing the BroadVision server alias, see the webMethods BroadVision Adapter User Guide, Chapter3, “Implementing the Inbound Adapter”.

Lesson 1 Exerc ise

Defining a BroadVision Server Alias

Caution: You must have administrator privileges on the webMethods Integration Server to perform the following procedure.

To define an alias

1. Start the webMethods Integration Server and the webMethods Integration Server Administrator. See the webMethods Integration Server Administrator’s Guide for the procedures to do this.

2. In the Adapters menu in the navigation area, select BroadVision55. The BroadVision55 child window is displayed.

3. In the BroadVision55 menu in the navigation area, select Alias Settings. The Alias Settings window is displayed.

4. Click the Add Alias Settings button. The Add Alias Settings window is displayed.

Complete the following fields. You may need to ask your BroadVision server administrator for the values for these fields.

Page 11: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 1 E x e r c i s e

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 11

Note: All entries are case sensitive!

In this field… Specify…

Alias Name A unique name for this alias. (This is the name by which Services will reference this alias.) For this exercise, type: Tutorial

Description Text that describes the alias. Optional.

IT_NAMES_SERVER_HOST

The machine on which you want to connect to the NamingService when you call resolve_initial_references. Type: hostName.companyName.com For example: odin.east.webmethods.com

IT_NS_PORT The port number at which the Names Server can be contacted. For this exercise, type: 1221

IT_NAMES_SERVER The name with which the Names Server is registered in the Implementation repository. This name is usually NS. For this exercise, type: bv1to1/bvconf_srv_a

IT_LOCAL_DOMAIN The local DNS domain name. Optional. For example: east.webmethods.com

IT_DAEMON_PORT The port number for the Orbix daemon. For this exercise, type: 1221

5. Click Save. The webMethods Integration Server Administrator saves the values to

Page 12: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 1 M a n a g i n g A l i a s S e t t i n g s

12 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

the Repository under the specified alias name. The Alias Settings window is re-displayed, showing the alias name you created. Using this window, you can edit, test, or delete the alias. If you receive an error message when you click Save, verify that the settings you specified are correct.

Testing the Alias You can perform a simple “health-check” to test the alias you just created. When you test an alias, the webMethods Integration Server tries to open and close a connection with the BroadVision Server referenced by the alias. It then displays a message that will tell you about the status of your alias.

To test your new alias

Test the newly created BroadVision Server alias by clicking the Test Connection icon in the Alias Settings List screen next to the alias.

If the test is successful, you will see the following message: “tutorial alias setting tested successfully.” If you did not successfully open a session with the BroadVision Server, verify the connection information and retry.

End of Lesson 1 The next lesson will show you how to create and test the insertProduct service.

Page 13: Web Methods Broad Vision Adapter Tutorial V1

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 13

L E S S O N

Creat ing and Test ing the Flow service insertProduct

Objectives..................................................................................14

Background................................................................................14

Lesson 2 Exercise .....................................................................14

Page 14: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 1 C r e a t i n g a n d T e s t i n g t h e F l o w s e r v i c e i n s e r t P r o d u c t

14 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Ob ject ives In this lesson, you will create the Flow service insertProduct, which will enable you to update your inventory list with Snowboard Supplier product information. Then, you will test the service, using the webMethods Developer.

Background After you execute the predefined Flow service getCatalog, Snowboard Suppliers returns the requested catalog item to your JavaScript page. Then, the BroadVision runtime service BVI_ContentManager queries your back-end system to find out whether the catalog item already exists in your system.

If Snowboard Suppliers returns a catalog item that does not exist in your back-end system, you must be able to add it to the system. To do this, you create a Flow service named insertProduct, which is handled by the inbound (Integration Server-to-BroadVision) adapter. This service must include the following entities that we provide:

�� The CORBA interface method insert_content To implement this method, you use the inbound (Integration Server-to-BroadVision) adapter’s user interface to generate the method to produce a Flow service. This generated service represents the method.

�� The Java service insert_content_attributes

Before you create insertProduct, you must enable your BroadVision Interface Repository (IFR) and then add to the IFR the IDL file associated with a CORBA server that we provide.

Lesson 2 Exerc ise

Adding the Example IDL File to the Interface Repository This tutorial provides the CORBA server CntMgmt/CntDB/cntdb1 and its associated .idl file cntdb. In this part of the exercise, you must first enable your BroadVision Interface Repository (IFR). Then, to make this CORBA server available to the inbound adapter, you must add the server’s IDL file to your IFR.

To enable the IFR and to add the example IDL file

1. Enable your BroadVision Interface Repository (IFR) by running the following commands on the BroadVision Server:

Page 15: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 2 E x e r c i s e

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 15

putit IFR /opt/bv1to1/orbix/bin/ifr chmodit IFR i+all

2. Run the following Orbix command to give the client “invoke and launch” permissions to the IFR: chmodit IFR l+all

3. To add IDL file cntdb.idl, run the following Orbix command: putidl –I /opt/bv1to1/include/idl/

/opt/bv1to1/include/idl/bv/cntdb.idl

Generating the CORBA Method insert_content for the Flow service insertProduct In this part of the exercise, you will use the adapter’s user interface to generate the CORBA interface method insert_content, which you will include in the Flow service insertProduct. Generating insert_content produces a Flow service that represents it.

To generate the insert_content method

1. In the BroadVision55 menu in the navigation area, select CORBA Servers. The Select Alias window is displayed.

2. Select your alias name from the Select an alias field’s drop-down list and click the Continue button. The BroadVision CORBA Servers from the Names Server window is displayed. This window displays all CORBA servers that exist in your BroadVision naming service.

3. Select the CORBA server CntMgmt/CntDB/cntdb1. The list of the server’s interfaces is displayed.

4. Select the interface BV_ContentDB from the list. A list of the interface’s methods and their return types are displayed.

5. Select the method insert_content from the list.

Page 16: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 1 C r e a t i n g a n d T e s t i n g t h e F l o w s e r v i c e i n s e r t P r o d u c t

16 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

The method’s parameters are displayed along with flow information fields.

6. Complete the following flow information fields to specify where to store the Flow service that you will generate for the CORBA method:

In this field… Specify…

Package The package in which to store the generated Flow service. For this exercise, type Default.

Folder The folder in which to store the generated Flow service. For this exercise, type Tutorial.

Service The Flow service name. Use the default name, which is the CORBA method name.

Description Text that describes the Flow service. Optional.

7. Click the Generate Flow Service button. The adapter generates the Flow service and stores it in the location you specified.

Creating the Flow service insertProduct In this part of the exercise, you will use the webMethods Developer to create insertProduct. When you create insertProduct, you will include the service insert_content that you just generated. In addition, you will copy the provided Java service insert_content_attributes that insert_content needs.

To create the insertProduct service

1. Start the webMethods Developer.

2. Click on the Tutorial folder in the Default package.

3. Click the New icon on the Service Browser toolbar.

4. Select the Flow Service option and click Next. 5. Assign the name insertProduct to the new flow service and click

Next.

6. Ensure that the Empty Flow option is selected and click Finish.

7. Click on the Flow Pane (the top pane).

8. Click the (Insert) icon on the toolbar in the Flow Pane.

9. Select Browse from the pull-down menu.

10. Select the insert_content_attributes service from the BroadVisionExample folder in the WmBVExample package and click OK.

11. Click the (Insert) icon again and select Browse from the pull-down menu.

Page 17: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 2 E x e r c i s e

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 17

12. Select the insert_content service from the Tutorial folder in the Default package and click OK.

13. Click on the insert_content_attributes service.

14. Highlight the PROD_ID, NAME, and PRICE fields in Pipeline In, right-click on them, and select Copy.

15. Click the Input/Output tab at the bottom of the pane.

16. Paste the copied fields in the Input section of the pane.

17. Click the Flow tab at the bottom of the pane.

18. Click on insert_content_attributes.

19. Click on the PROD_ID field in Pipeline In, click on the OID field in Service In, and map these fields to each other.

20. Save the flow service.

21. Click on the OID, PROD_ID, NAME, and PRICE fields in Pipeline Out and click on the Drop icon to drop these fields. The completed service should look like this:

Page 18: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 1 C r e a t i n g a n d T e s t i n g t h e F l o w s e r v i c e i n s e r t P r o d u c t

18 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

22. Click on insert_content in the Flow pane (the top pane).

23. Map attrList in Pipeline In to attrList in Service In.

24. Click on the ALIASNAME field in Service In and click the Set Value icon to assign an input value for the field.

25. In the dialog box that is displayed, type the input value Tutorial and click OK.

26. Assign the following values for the following fields in Service In: Field Value

store_id 90

cnt_type 0

user_id 0

27. Save the flow service.

28. In Pipeline Out, drop the fields ALIASNAME, attr_list, and attrList. The completed flow service should look like this:

Page 19: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 2 E x e r c i s e

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 19

Testing the Flow service insertProduct In the final part of the exercise, you will use the webMethods Developer to test insertProduct. Since this service is executed in your (SGD’s) webMethods Integration Server, the request is handled by the inbound (Integration Server-to-BroadVision) adapter.

To test the insertProduct service

1. In the webMethods Developer window, expand the Default package.

2. Expand the Tutorial folder.

3. Select the insertProduct service in the folder.

4. Click the (Run) icon on the Service Browser toolbar to run the service. A pop-up dialog box is displayed, prompting you for input values for the flow service’s purchase order.

5. Type the following values in the dialog box and click OK.

Field Value

PROD_ID 111111

NAME Deluxe Snowboard

PRICE 999.97

If the service was successfully executed, your webMethods Developer screen should display the results shown on the next page:

Page 20: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 1 C r e a t i n g a n d T e s t i n g t h e F l o w s e r v i c e i n s e r t P r o d u c t

20 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

End of Lesson 2 The next lesson will show you how to create and test the delete_content_by_key service.

Page 21: Web Methods Broad Vision Adapter Tutorial V1

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 21

L E S S O N

Creat ing and Test ing the Flow service delete_content_by_key

Objectives..................................................................................22

Background................................................................................22

Lesson 3 Exercise .....................................................................22

Page 22: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 5 C r e a t i n g a n d T e s t i n g t h e F l o w s e r v i c e d e l e t e _ c o n t e n t _ b y _ k e y

22 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Ob ject ives In this lesson, you will create the Flow service delete_content_by_key, which you will use to delete the products you added with insertProduct. Then, you will test the service, using the webMethods Developer.

Background The tutorial provides a CORBA interface method named delete_content_by_key. You implement this method the same way you implemented insert_content. That is, you use the inbound (Integration Server-to-BroadVision) adapter’s user interface to generate the method to produce a Flow service that represents the method.

Lesson 3 Exerc ise

Generating the delete_content_by_key Service In this part of the exercise, you will use the BroadVision Adapter to generate the delete_content_by_key method to produce the flow service delete_content_by_key.

To generate the delete_content_by_key method

1. In the BroadVision55 menu in the navigation area, select CORBA Servers. The Select Alias window is displayed.

2. Select your alias name from the Select an alias field’s drop-down list and click the Continue button. The BroadVision CORBA Servers from the Names Server window is displayed. This window displays all CORBA servers that exist in your BroadVision naming service.

3. Select the CORBA server CntMgmt/CntDB/cntdb1. The list of the server’s interfaces is displayed.

4. Select the interface BV_ContentDB from the list. A list of the interface’s methods and their return types are displayed.

5. Select the method delete_content_by_key from the list. The method’s parameters are displayed along with flow information fields.

Page 23: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 3 E x e r c i s e

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 23

6. Complete the following flow information fields to specify where to store the Flow service that you will generate for the CORBA method:

In this field… Specify…

Package The package in which to store the generated Flow service. For this exercise, type Default.

Folder The folder in which to store the generated Flow service. For this exercise, type Tutorial.

Service The Flow service name. Use the default name, which is the CORBA method name.

Description Text that describes the Flow service. Optional.

7. Click the Generate Flow Service button. The adapter generates the Flow service and stores it in the location you specified.

Testing the delete_content_by_key Service In this part of the exercise, you will use the webMethods Developer to test the delete_content_by_key service. Since this service is executed in your (SGD’s) webMethods Integration Server, the request is handled by the inbound (Integration Server-to-BroadVision) adapter.

To test the delete_content_by_key service

1. In the webMethods Developer window, expand the Default package.

2. Expand the Tutorial folder.

3. Select the delete_content_by_key service in the folder.

4. Click the (Run) icon on the Service Browser toolbar to run the service. A pop-up dialog box is displayed, prompting you for input values for the flow service’s purchase order.

5. Type the following values in the dialog box and click OK.

Field Value

ALIASNAME Tutorial

store_id 90

cnt_type 0

Key Enter the PROD_ID value that you used to add the product with the insertProduct service. For example, if you entered the PROD_ID value 111111 to add the Deluxe Snowboard, enter the key value 111111 to delete it.

Page 24: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 5 C r e a t i n g a n d T e s t i n g t h e F l o w s e r v i c e d e l e t e _ c o n t e n t _ b y _ k e y

24 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Field Value

User_id 0

End of Lesson 3 The next lesson will show you how to run the tutorial in your web browser.

Page 25: Web Methods Broad Vision Adapter Tutorial V1

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 25

L E S S O N

Running the Tutoria l

Objectives..................................................................................26

Lesson 4 Exercise .....................................................................26

Page 26: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 5 R u n n i n g t h e T u t o r i a l

26 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Ob ject ives In this lesson, you will run the tutorial in your web browser.

Lesson 4 Exerc ise

To run the tutorial in your web browser

1. In your web browser, specify the following URL: http://hostNameOfBroadVisionServer/start.html where you substitute hostNameOfBroadVisonServer with your host name. This html page redirects to the JavaScript page start.jsp.

2. On the start.jsp page that is displayed, login to the tutorial by completing the following fields and clicking the Login button:

In this field… Type…

Host Your IP address.

Port Your host’s port number.

Username Your user name.

Password Your password.

3. Select the supplier Snowboard Supplier.

4. Select the product Deluxe Snowboard to determine whether it exists in your BroadVision back-end system. A message should be displayed, stating that this product exists in the system.

5. Click the Back button on your browser.

6. Select the product Economy Snowboard to determine whether it exists in your BroadVision back-end system. A message should be displayed, stating that this product does not exist in the system.

7. To add the Economy Snowboard to the back-end system, display the webMethods Developer.

8. Expand the Default package.

Page 27: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 4 E x e r c i s e

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 27

9. Expand the Tutorial folder.

10. Click the Flow service insertProduct.

11. Click the (Run) icon on the Service Browser toolbar to run the service. A dialog box is displayed, prompting you to enter input values for the service.

12. Enter the following input values and click OK:

Field Value

PROD_ID 222222

PRICE 599.97

NAME Economy Snowboard

13. Click your browser’s Back button to return to the previous page.

14. Select Economy Snowboard again. A message should be displayed, stating that the Economy Snowboard has been found in the system.

15. To delete Economy Snowboard, follow the procedure on the JavaScript page.

End of Lesson 4 The next lesson will show you how to use a session portal interface, which executes the tutorial’s JavaScript pages in your BroadVision Interaction Manager’s JavaScript engine, without going through a web server.

Page 28: Web Methods Broad Vision Adapter Tutorial V1
Page 29: Web Methods Broad Vision Adapter Tutorial V1

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 29

L E S S O N

Using a Session Portal Interface

Objectives..................................................................................30

Lesson 5 Exercise .....................................................................30

Page 30: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 8 U s i n g a S e s s i o n P o r t a l I n t e r f a c e

30 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Ob ject ives In this lesson, you will configure and test a session portal interface, which executes the tutorial’s JavaScript pages in your BroadVision Interaction Manager’s JavaScript engine, without going through a web server.

Lesson 5 Exerc ise

Verifying and Enabling the Installation of the Session Portal Piece of the Inbound (Integration Server-to-BroadVision) Adapter Before you can create a session portal interface, first verify that the proper supporting files were installed. Use the appropriate Windows or UNIX procedure for doing this.

To verify the session portal installation on a Windows platform

1. Ensure that the BroadVisiondll directory in your webMethods Integration Server directory contains the following DLL files:

• bvcore.dll

• bvidl.dll

• callin.dll

• itglm301.dll

• itlmm301.dll

• itm_m301.dll

• itolm301.dll

• libscfg.dll

• libsmgr_util.dll

• mny204d.dll

• remoteSession.dll

• tls704d.dll

• wmSessionPortal.dll

2. Ensure that your registry entry for BroadVision points to the configuration file bvsm.cfg, as follows:

a. Type regedit in a command line prompt to display the Registry Editor.

b. In the Registry Editor, expand the following directories:

Page 31: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 5 E x e r c i s e

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 31

HKEY_LOCAL_MACHINE\SOFTWARE\BroadVision\One-To-One Application System\5.5\Interaction Manager\default\export

c. Double click on the value name BV1TO1_SESSION_CFG in the export directory and ensure that its value is the following path: c:\bv1to1_var\BVSNsmgr\BroadVisionDll\bvsm.cfg

d. Double click on the value name Default and ensure that its value is identical to that of BV1TO1_SESSION_CFG.

Note: Your system administrator should give you the bvsm.cfg file. This file pertains to your default Interaction Manager (IM). However, if a named IM is running on your BroadVision server, you should copy that configuration file instead of bvsm.cfg. If you want to change your configuration file, shut down your webMethods Integration Server first.

To verify the session portal installation on a Solaris or HP-UX platform

Note: If you are installing on HP-UX, in the instructions below, replace the file suffix .so with the suffix .sl.

1. Verify that the file libwmSessionPortal.so appears in your webMethods

Integration Server’s lib directory.

2. Copy the files libsessionHandle.so.1 and libbvcCallin.so.1 from /opt/bv1to1/lib to ServerDirectory/lib.

3. Make sure you have execute permissions on the following files: libsessionHandle.so.1 libbvcCallin.so.1 libRemoteSession.so

4. Create the following directory in your system: /etc/opt/BVSNsmgr

5. Copy the file bvsm.cfg from your BroadVision Server’s /etc/opt/BVSNsmgr directory to your /etc/opt/BVSNsmgr.

Note: Your system administrator should give you the bvsm.cfg file. This file pertains to your default Interaction Manager (IM). However, if a named IM is running on your BroadVision server, you should copy that configuration file instead of bvsm.cfg. If you want to change your configuration file, shut down your webMethods Integration Server first.

Page 32: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 8 U s i n g a S e s s i o n P o r t a l I n t e r f a c e

32 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

Configuring the Session Portal Interface To create the session portal interface, you use the webMethods BroadVision Adapter.

To configure the session portal interface

1. Start the webMethods Integration Server and the webMethods Integration Server Administrator. See the webMethods Integration Server Administrator’s Guide for the procedures to do this.

2. In the Adapters menu in the navigation area, select BroadVision55. The BroadVision55 child window is displayed.

3. In the BroadVision55 menu in the navigation area, select Session Portal. The Execute JavaScript Page window is displayed.

4. Complete the following fields to provide the parameters for the session portal interface.

Field Description

BroadVision Application Name

The name of your BroadVision application. For this exercise, type default (if using a Windows platform) or bvsm (if using a UNIX platform).

JavaScript File The name of the JavaScript file, starting with the directory relative to the script root defined in your BroadVision installation. To provide access to the tutorial’s listsuppliers.jsp (which displays the list of suppliers), type: webmethods/scripts/listsuppliers.jsp

Input String The values to input to your JavaScripts. For this exercise, type: username=Administrator&password=manage&host=yourHost&port=yourPort where you replace yourHost and yourPort with your actual host and port values.

Size of the Output Specify a size of the result, if you expect to receive a result. For this exercise, type 0.

5. Click the Execute JSP button. The ExecuteJSP service executes the JavaScript page in the Interaction Manager and returns a status message.

Page 33: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 5 E x e r c i s e

webMethods BroadVision Adapter Tutorial VERSION 1.2 ���� ���� ���� 33

Testing the Session Portal Interface To test the session portal interface, you use the webMethods Developer.

To test a session portal interface

1. Start the webMethods Developer.

2. Expand the Default package.

3. Expand the Tutorial folder.

4. Click the Tutorial folder.

5. Click the New icon on the Service Browser toolbar.

6. Select the Flow Service option and click Next.

7. Assign the name sessionPortal t o the new flow service and click Next.

8. Ensure that the Empty Flow option is selected and click Finish.

9. Click on the Flow Pane (the top pane).

10. Click the (Insert) icon on the toolbar in the Flow Pane.

11. Select Browse from the pull-down menu.

12. Select the Java service ExecuteJSP from the directory BroadVision55\wm\broadvision55\corba\BroadvisionAdmin.

13. Copy the fields APPNAME, SCRIPTNAME, INPUT, and SIZE from Service In.

14. Click the Input/Output tab and paste the copied fields into the input pane.

15. Click the Flow tab.

16. Click the (Insert) icon again and select stringToDocument from the pull-down list.

17. Click on stringToDocument and map the OUTPUT field in Pipeline In to the xmldata field in Service In.

18. Click the isXML field in Service In and click the Set Value icon on the Pipeline toolbar.

19. Set the value of isXML to false.

20. Click the (Insert) icon again and select documentToRecord from the pull-down list.

Page 34: Web Methods Broad Vision Adapter Tutorial V1

L e s s o n 8 U s i n g a S e s s i o n P o r t a l I n t e r f a c e

34 ���� ���� ���� webMethods BroadVision Adapter Tutorial VERSION 1.2

21. Click the sessionPortal service name.

22. Click the (Run) icon on the Service Browser toolbar to run the service. A pop-up dialog box is displayed, prompting you for input values for the flow service’s purchase order.

23. Type the following values in the dialog box and click OK.

Field Value

APPNAME default (if using Windows) or bvsm (if using UNIX)

SCRIPTNAME webmethods\scripts\listsuppliers.jsp

INPUT username=Administrator&password=manage&host=yourHost&port=yourPort where you replace yourHost and yourPort with your actual host and port values.

SIZE 0 The results that are displayed should show the value of the xmldata field as the html page List of Suppliers.

End of Lesson 5 Congratulations! You have completed the tutorial.

Page 35: Web Methods Broad Vision Adapter Tutorial V1

webMethods BroadVision Adapter Tutorial

V E R S I O N 1 . 2

webMethods, Inc. 3930 Pender Drive Fairfax, VA 22030 USA 703.460.2500 http://www.webmethods.com

Page 36: Web Methods Broad Vision Adapter Tutorial V1

webMethods for Trading Networks, webMethods for Partners, webMethods Developer, webMethods Integration Server, webMethods EDI Adapter, and the webMethods logo are trademarks of webMethods, Inc. “webMethods” is a registered trademark of webMethods, Inc. All other marks are the property of their respective owners.

Copyright © 2001 by webMethods, Inc. All rights reserved including the right of reproduction in whole or in part in any form.

webM-BroadVision-Tutorial-20010719

Page 37: Web Methods Broad Vision Adapter Tutorial V1
Page 38: Web Methods Broad Vision Adapter Tutorial V1
Page 39: Web Methods Broad Vision Adapter Tutorial V1

���� ���� ���� i

C O N T E N T S

Introduction.....................................................................................................................................1 Welcome! ............................................................................................................................................................... 2

System Requirements..................................................................................................................................... 2 Prerequisite Skills............................................................................................................................................ 2

Architecture and Components................................................................................................................................ 3 The Global Sporting Goods Case Study ................................................................................................................ 3

The Problem.................................................................................................................................................... 3 The Solution .................................................................................................................................................... 4

Installing the Tutorial .....................................................................................................................5 Installing the BroadVision Adapter and Tutorial ..................................................................................................... 6 Setting up the BroadVision Adapter Tutorial .......................................................................................................... 6

Managing Alias Settings ................................................................................................................9 Objectives............................................................................................................................................................. 10 Background .......................................................................................................................................................... 10 Lesson 1 Exercise ................................................................................................................................................ 10

Defining a BroadVision Server Alias ............................................................................................................. 10 Testing the Alias............................................................................................................................................ 12

Creating and Testing the Flow service insertProduct ...............................................................13 Objectives............................................................................................................................................................. 14 Background .......................................................................................................................................................... 14 Lesson 2 Exercise ................................................................................................................................................ 14

Adding the Example IDL File to the Interface Repository.............................................................................. 14 Generating the CORBA Method insert_content for the Flow service insertProduct ...................................... 15 Creating the Flow service insertProduct........................................................................................................ 16 Testing the Flow service insertProduct ......................................................................................................... 19

Creating and Testing the Flow service delete_content_by_key ...............................................21 Objectives............................................................................................................................................................. 22 Background .......................................................................................................................................................... 22

Page 40: Web Methods Broad Vision Adapter Tutorial V1

ii ���� ���� ����

Lesson 3 Exercise.................................................................................................................................................22 Generating the delete_content_by_key Service ............................................................................................22 Testing the delete_content_by_key Service ..................................................................................................23

Running the Tutorial.....................................................................................................................25 Objectives .............................................................................................................................................................26 Lesson 4 Exercise.................................................................................................................................................26

Using a Session Portal Interface .................................................................................................29 Objectives .............................................................................................................................................................30 Lesson 5 Exercise.................................................................................................................................................30

Verifying and Enabling the Installation of the Session Portal Piece of the Inbound (Integration Server-to-BroadVision) Adapter.....................................................................................................................................30 Configuring the Session Portal Interface .......................................................................................................32 Testing the Session Portal Interface..............................................................................................................33