Show TOC Start of Content Area

Procedure documentation Debugging Web Dynpro Implementations  Locate the document in its SAP Library structure

Use

The NetWeaver Developer Studio provides tools for debugging your coding in Web Dynpro applications. For this purpose you can set breakpoints in the controller implementations of Web Dynpro applications. As with other Java code, you create reusable launch configurations and then use the debug perspective to debug the code.

Prerequisites

·        The server that you want to debug on, is configured as debuggable server.

More information: Configuring Instances

 Note

In the Process Table list of the AS Java node, in the Debug column, the node of the server is indicated as Switched off, i.e., you can reserve the instance for debugging. If the server is not debuggable, you find Disabled here. If the instance is reserved by another debug session, the corresponding debug entry is displayed here.

      You have access as OS user, with administration access to the SAP System (<SID>adm)

Procedure

Enabling Server for Debugging

By default, debugging is deactivated on the server, even if the server is debuggable. Activate debugging for the time you debug on the server (debugging on demand). In the Start Debug dialog box, do not use the default settings. Under Expert Mode, deselect the Load Isolation indicator instead.

More information: Enabling and Disabling the Debug Mode  

Creating Reusable Launch Configurations

You can configure debug configuration settings for a project and save them for reuse.

...

       1.      Choose Run Open Debug Dialog. 

       2.      In the Debug dialog box, expand the node SAP Application. Select the relevant configuration or select New_configuration.

       3.      On the right-hand side, in the Module tab, make the required settings for the launch configuration, as explained in the following table.

Field Name

Description

Steps

Module

The deployable unit that you want to debug

      Choose Browse

      In the Modules dialog box, select the module

      Choose OK

Module Type

Type of the module, such as, Web Dynpro Module

 

Module Artifact

The module entity that you launch

...

      Choose Browse

      In the Module Artifacts dialog box, select the module artifact

      Choose OK

Note

To build the module and deploy the archive to the server, select Build and Deploy.

       4.      To use a custom URL to launch the module, select the Use Custom Launch URL option, and modify the URL in the Launch URL field.

Note

By default, the system uses the default URL to launch the module.

       5.      In the Runtime tab, select the required SAP system, the debug instance, and the server node.

Note

By default, the system uses the first debug instance and server node.

       6.      In the Source tab, add the development components that should be part of the source lookup. If your module has dependent development components, you might require them during the debug session.

       7.      Choose Apply.

Starting Debugging

The debugger enables you to detect and diagnose errors in your Web Dynpro application. You control the execution of your program by setting breakpoints.

...

       1.      In Web Dynpro Explorer, select the view or controller that you want to debug.

       2.      From the context menu, start the Java Editor for the view or the controller.

       3.      Create breakpoints where the application is to be stopped for error or behavior diagnosis.

For more information about the handling of breakpoints and navigating through the coding, read the corresponding Eclipse documentation.

       4.      To start debugging for the first time, in the Debug dialog box choose Debug.

A dialog box to switch the display to the Debug perspective appears by default, when needed.

       5.      Choose Yes.

The source code is now displayed in the Debug perspective and execution starts.

If asked, enter your Software Deployment Manager (SDM) password.

 Note

SDM is the standard tool for installing Java Enterprise Edition (JEE) components on the Java Engine.

       6.      To select a Web browser to launch the application, choose Window Web Browser.

You can choose one of the following three options:

¡        Internal Web Browser

¡        Default System Web Browser

¡        Internet Explorer

Stopping Debugging

...

       1.      In the Debug view, select the node for the configuration to be stopped.

       2.      In the context menu, choose Terminate.

More Information

Debugging Contexts

End of Content Area