Vous êtes sur la page 1sur 5

Steps to debug Application entry insert issue with frevvo Setup the VM with the image

In the settings choose the network mode as NAT

Start the Machine. Login with username and password (oracle/oracle) In the Menu, Choose Start Graphical Desktop. After going to the Graphical Desktop, check the Server status and details by going to Manage Weblogic Servers. Open Jdeveloper and open the unzipped Application (Application 5) in jdev, if not already open. Do this by clicking New Application, going to the Application5 directory and choosing the jws of the Application. Adding other files onto the project: If you want to add other files onto the project (some frevvo files) you can add it in the Project source path in the Project Properties Window (Point 9), Do this after deployment or the compiler will throw exceptions. Debugging: Now a bit on the structure of the code. There are 2 files in this project that are important. FormDesignerBean.java and formDesignerPage.jspx. FormDesignerBean.java contains the code for opening the designer that is invoked at the click of the button in formDesignerPage. The formDesignerPage is shown below

The Launch Designer button invokes the launchDesigner method in the FormDesignerBean. This method calls the getFormEditorUrl() which returns the URL for the form editor. A screenshot of the method is shown below

You can add break points now in the bean at the place you want to investigate. In this scenario the code fails at applicationEntry = applicationFeed.insert(applicationEntry); So you can add the break point there by clicking in the left column of that particular line. It is shown in the below screenshot. Click at where the box is, in the screenshot below.

Once the breakpoints are added you can launch an instance in the browser and investigate the exception. Before this 2 things are needed to be done 1. Remove the proxy on the firefox browser. This ensures the the proxy does not interfere with the page since it is localhost. 2 .Log into the composer. Since we dont provide the username and password in the code (you are assumed to be logged in since this module will be in the Administration UI), you will need to login to composer and then launch an instance. Else it will break at alui. Loginas(). To login to Composer go to http://soabpm-vm.site:7001/bpm/composer, and login as weblogic/welcome1.

Launch the instance. For this you need to start the server in debug mode. For that we need to go to the Manage Weblogic Servers on the desktop and enable the remote debugging for AdminServer by checking that box in the Remote Debugging tab in the manager. Then we need to restart the server. Go back to the server control tab in the manager window and select AdminServer, stop it. After it completely stops (you can check in the log at /home/oracle/logs/AdminServer.log ). Then start it again. It will pause saying you need to start the remote debugging (of the application through jdev) to continue startup of the server. We will see how to do that in the next step. Below are screenshots on how to enable the remote debugging and how to restart the server. Enabling the debug mode in the AdminServer

Stopping and Starting the Server in the Manage Weblogic Servers window.

You can track the progress of the server in /home/oracle/logs/AdminServer.log. When the

server starts it says SOA Platform is running and accepting requests. It also shows the exception on the log after the debug is complete. Go back to Jdev and right click View Controller and Start Remote Debugging, as shown

The debugger will ask you to verify the details of the server (localhost, port : 4000). If its fine click ok. The debugger will connect onto the server. Now the server will continue the start up which was paused in the previous step. You can track the progress of the server in /home/oracle/logs/AdminServer.log. When the server starts it says SOA Platform is running and accepting requests. You can then hit the url http://soabpm-vm.site:7001/Application1/faces/formDesignerPage.jspx and click the Launch Designer button. This will hit the break point and you can see the data at the break point as shown below. You can switch to the next line (yellow box) , enter into the method (red box) , or switch to the next breakpoint (black box).

Vous aimerez peut-être aussi