Debugging Application Engine Programs 调试应用程序引擎程序

本文主要是介绍Debugging Application Engine Programs 调试应用程序引擎程序,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

Debugging Application Engine Programs

调试应用程序引擎程序

This section discusses how to:

本节讨论如何:

  • Enable the Application Engine debugger.
  • 启用应用程序引擎调试器。
  • Set debugging options.
  • 设置调试选项。
Enabling the Application Engine Debugger
启用应用程序引擎调试器

To run a program in debug mode:

在调试模式下运行程序:

  1. Set the debug option.

设置调试选项。

You can set the debug option in the following locations:

您可以在以下位置设置调试选项:

    • Start PeopleSoft Configuration Manager and select the Process Scheduler tab.
    • 启动PeopleSoft配置管理器并选择进程调度器选项卡。

In the Application Engine group, enable debug by selecting the Debug check box. This method applies to all methods of invocation.

在“应用程序引擎”组中,通过选中“调试”复选框启用调试。此方法适用于调用的所有方法。

    • If you used the command line option to invoke your Application Engine program, then you can include the −DEBUG Y parameter in the command line you submit to PSAE.EXE.
    • 如果您使用命令行选项来调用应用程序引擎程序,则可以在提交给PS AE.EXE的命令行中包含DEBUG Y参数。

If the Debug check box is already selected in PeopleSoft Configuration Manager, then you do not need to include the −DEBUG parameter in your command line.

如果已在PeopleSoft Configuration Manager中选中了Debug复选框,则不需要在命令行中包含DEBUG参数。

Note: Setting debug capabilities in either PeopleSoft Configuration Manager or the command line turns debug mode on. However, if you have debug enabled in Configuration Manager and you submit −DEBUG N on the command line, then the PeopleSoft Configuration Manager setting defines your default command line value and the command line can override the default.

附注:在PeopleSoft Configuration Manager或命令行中设置调试功能将打开调试模式。但是,如果您在配置管理器中启用了调试,并且在命令行上提交了-DEBUG N,则PeopleSoft配置管理器设置将定义您的默认命令行值,并且命令行可以覆盖默认值。

    • If you have PeopleCode in your Application Engine program, enable the PeopleCode debugger.
    • 如果您的应用程序引擎程序中有PeopleCode,请启用PeopleCode调试器。

When you launch your program and the PeopleCode action runs, enter the PeopleCode debugger.

启动程序并运行PeopleCode操作时,输入PeopleCode调试器。

  1. Run the Application Engine program to debug.

运行应用程序引擎程序进行调试。

  1. At the Application Engine Debugger prompt, enter a command to enable a debugging option.

在“应用程序引擎调试器”提示符下,输入命令以启用调试选项。

Each command is represented by a single letter, such as X, L, or M. Enter the letter that corresponds to the option you want to engage. To see a list of the available debugging options, enter? at the prompt.

每个命令都由一个字母表示,如X、L或M。输入与要接合的选项对应的字母。要查看可用调试选项的列表,请输入?在提示符下。

To enable the PeopleCode debugger for Application Engine:

要为应用程序引擎启用PeopleCode调试器,请执行以下操作:

  1. Sign on to PeopleTools using the same user ID that you will use to invoke the Application Engine program.

使用您将用于调用应用程序引擎程序的相同用户ID登录到PeopleTools。

  1. Open Application Designer.

打开应用程序设计器。

  1. Select Debug, PeopleCode Debugger Mode.

选择Debug,PeopleCode调试器模式。

Your Application Engine program can be open on the desktop, but you do not need to open the Application Engine program or the PeopleCode action that you want to debug.

可以在桌面上打开应用程序引擎程序,但不需要打开要调试的应用程序引擎程序或PeopleCode操作。

  1. Select Debug, Break at Start.

选择“调试”,“在开始时断开”。

This command will cause the Application Engine program to break before executing any PeopleCode programs within it.

该命令将导致应用程序引擎程序在执行其中的任何PeopleCode程序之前中断。

Setting Debugging Options
设置调试选项

Each debugger option is represented by a single letter that you specify at the prompt. To engage the option you select, press  Enter.

每个调试器选项由您在提示符处指定的单个字母表示。要启用所选选项,请按Enter。

Debugging Tips

调试提示

Become familiar with these tips about debugging programs:

熟悉这些调试程序的技巧:

  • In some cases, such as when setting breakpoints or watch fields, submenus offer additional options.
  • 在某些情况下,例如设置断点或监视字段时,子菜单会提供额外的选项。

After you are familiar with the commands, you can enter multiple items on the command line to combine commands and bypass the submenus. For example, to see a list of the breakpoints, you could enter B L.

在熟悉了这些命令之后,可以在命令行中输入多个项来组合命令并绕过子菜单。例如,要查看断点列表,可以输入BL。

To set a field as a watch field, you could enter W S MY_FIELD.

要将字段设置为监视字段,您可以输入W S MY_FIELD。

To set a field as a watch field on a different state record, enter W S MY_AET.MY_FIELD.

要将字段设置为其他状态记录上的监视字段,请输入W S MY_AET.MY_FIELD。

Note: The exception to this option is Modify, which always displays the current value and then prompts you to enter a new value. You can, however, enter M MY_AET.MY_FIELD to go directly to the new value prompt.

附注:此选项的例外是“修改”,它始终显示当前值,然后提示您输入新值。但是,您可以输入M MY_AET.MY_FIELD直接转到新的值提示符。

  • Letter commands are not case-sensitive.
  • 字母命令不区分大小写。

For example, Q and q are valid commands.

例如,Q和q是有效的命令。

Debugging Options

Option

Description

Quit

Enter Q. This option performs a rollback on the current unit of work in the debugging run, and it ends the debugging session.

 It effectively terminates your Application Engine program.

Quit is useful for testing restart. Have some work committed and some uncommitted. Then, terminate the program at that point and roll back the pending work. You want to make sure the program restarts from the point of the last successful commit.

Exit

This option is valid only after one step has completed and another has not already begun. It is not valid once you reach the action level.

Use this option as an alternative to Quit. Exit ends the program run and the debugging session, but it also commits the current unit of that the program has already completed. This option can be helpful when testing your restart logic.

Commit

Enter C to commit the current unit of work in your program.  This option is valid only after a step has completed and before another begins. It is not valid after you reach the action level.

You can use this option, for example, to use your database query tool to check the data in your database.

Break

Enter B to set a breakpoint. When the program reaches the breakpoint, it temporarily halts execution to enable you to observe the state of the current process.

Breakpoint options include:

Set: Enter S to set a breakpoint location.

The breakpoint location appears by default at the current location in the program, but you can specify other sections or steps by overriding the default values that appear in brackets.

Unset: Enter U to remove breakpoints previously set.

List: Enter L to list breakpoints. When you enter this command, make sure that you have entered B first to specify the break option. If you enter L from the main command prompt, you engage the Look option.

Option

Description

Look

Enter L to observe the values currently in the state record associated with the program you are debugging. You must specify the state record at the Record Name prompt. By default, the default state record as specified in your program properties appears in brackets.

You can also specify a specific field name on the state record in the Field Name prompt. To look at all the fields in the state record, leave the asterisk (*) within the brackets unchanged.

Modify

Enter M to modify the value of a state record value for debugging purposes. Suppose the previous steps did not set a value correctly but you want to see how the rest of the program would perform if the appropriate value existed in the state record. This option enables you to help your program in the debugging or testing phase.

As with the Look command, you must specify the appropriate state record (if you are using multiple state records), and you must specify one field. You can modify only one field at time.

Watch

Enter W to specify a field as a watch field. The program stops when the field value changes.

Similar to the Break command, you can specify options for Set, Unset, and List.

Step Over

Enter S to run the current step to completion and stop at the next step in the current section.

The behavior depends on the current level or the program.  You start at the step level, and then can step into the action level. If you are at the step level and use step over, you go to the next step in the current section, skipping over all actions (including any call sections). If you are at the action level, step over executes the current action and stops at the next action in the current step, or at the next step in the current section.

Option

Description

Step Into

Enter I to observe a step or called section in more detail. For instance, you can check each SQL statement and stop. By using this option and checking the state record at each stop,  you can easily isolate problem SQL or PeopleCode.

As with Step Over, the behavior depends on the level. At the step level, you can step into the action level and stop before the first action in the step. At the action level, if the current action is a call section, this option takes you to the first step in the called section. For other action types, this option acts the same as the Step Over option because no deeper level exists in which to step.

Step Out of

Liz Enter O. After you’ve stepped into a step or called section,  use the Step Out of option to run the rest of the current step or called section and stop. As with the previous step options,  the behavior of Step Out of depends on the current level of the program.

At the step level, Step Out of completes the remaining steps in the current section, returns to the calling section or step, and stops at the next action in that step. If the section is MAIN and is not called by another section or step, then Step Out of behaves the same as the Go option.

At the action level, Step Out of completes the current step and stops at the next step in the current section, or if the program is at the end of a section, Step Out of returns to the calling section or step.

Go

Enter G. After the program has stopped at a specific location,  and you’ve examined its current state, you can use the Go command to resume the execution of the program. This is a helpful command when you have breakpoints set. With this command, the program won’t stop at a step or action; it only stops at the next breakpoint or watch field, or when the program runs to completion.

Run to commit

Enter R. Resumes execution of your program after it has stopped. This command forces the program to stop again after the next commit. This is a good option to use when observing your commit strategy and how it will affect a restart.

Example of the Look Option

外观选项的示例

To view the value stored in a specific field of the state record after a step or action, enter the appropriate field name at the Field Name prompt. For example, if you entered AE_TESTAPPL_AET at the Record Name prompt and AE_INT_6 at the Field Name prompt, you would see the value of the AE_INT_6 field in the AE_TESTAPPL_AET record.

要在步骤或操作之后查看存储在状态记录的特定字段中的值,请在Field Name提示符处输入适当的字段名。例如,如果您在记录中输入了AE_TESTAPPL_AET名称提示符和AE_INT_6在字段名称提示符下,您将在AE_TESTAPPL_AET记录中看到AE_INT_6字段的值。

You can also use an asterisk (*) as a wildcard to get a partial list. For example, if you enter AE_INT* at the Field Name prompt, you see only the fields that start with AE_INT; this is also true for the Record Name prompt. This feature is useful for both listing multiple fields across multiple records and as a shortcut. If you know that only one state record starts with XXX, you do not have to type the full name, just type XXX.

您也可以使用星号(*)作为通配符来获取部分列表。例如,如果输入AE_INT*在字段名提示符时,您只看到以AE_INT开头的字段;对于Record Name提示符也是如此。此功能对于列出跨多个记录的多个字段以及作为快捷方式都很有用。如果您知道只有一个状态记录以XXX开头,则不必键入全名,只需键入XXX即可。

Example of the Modify Option

修改选项的示例

If you wanted to set the AE_INT_15 field in the AETESTPROG to 10, you would enter the record (AE_TESTAPPL_AET) at the Record Name prompt and the field (AE_INT_15) at the Field Name prompt.

如果你想将AETESTPROG中的AE_INT_15字段设置为10,你可以在记录名称提示符处输入记录(AE_TESTAPPL_AET),在字段名称提示符处输入字段(AE_INT_15)。

Then you would see the current value of the field. At the prompt, you could enter a new value.

然后您将看到该字段的当前值。在提示符下,您可以输入一个新值。

Using the Look command, you can check to see that the value you specified now exists in the state record.

使用Look命令,可以检查指定的值现在是否存在于状态记录中。

Example of the Watch Option

监视选项示例

Enter S to set a watch field. After you enter S, you enter the record name (such as AE_TESTAPPL_AET) and field name (such as AE_INT_7) at the appropriate prompts.

输入S以设置监视字段。输入S后,在适当的提示下输入记录名(如AE_TESTAPPL_AET)和字段名(如AE_INT_7)。

Enter U to unset, or remove, a watch field from the list. After you enter U, you see a list of active watch fields. Enter the watch field ID number to remove a field. For example, if the field AE_INT_7 were second in the watch field list, you would enter 2 to remove it.

输入U可从列表中取消设置或删除监视字段。输入U后,您会看到活动监视字段的列表。输入监视字段ID号以删除字段。例如,如果字段AE_INT_7在监视字段列表中排在第二位,则输入2将其删除。

After a step or action completes, enter L to list, or view, the values of all the fields that you included in the watch list.

完成步骤或动作后,输入L以列出或检视监视清单中包含的所有字段的值。

Note: You cannot set a watch on a long text field.

注意:您不能在长文本字段上设置监视。

这篇关于Debugging Application Engine Programs 调试应用程序引擎程序的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/460360

相关文章

LiteFlow轻量级工作流引擎使用示例详解

《LiteFlow轻量级工作流引擎使用示例详解》:本文主要介绍LiteFlow是一个灵活、简洁且轻量的工作流引擎,适合用于中小型项目和微服务架构中的流程编排,本文给大家介绍LiteFlow轻量级工... 目录1. LiteFlow 主要特点2. 工作流定义方式3. LiteFlow 流程示例4. LiteF

SpringBoot集成LiteFlow实现轻量级工作流引擎的详细过程

《SpringBoot集成LiteFlow实现轻量级工作流引擎的详细过程》LiteFlow是一款专注于逻辑驱动流程编排的轻量级框架,它以组件化方式快速构建和执行业务流程,有效解耦复杂业务逻辑,下面给大... 目录一、基础概念1.1 组件(Component)1.2 规则(Rule)1.3 上下文(Conte

Python基于微信OCR引擎实现高效图片文字识别

《Python基于微信OCR引擎实现高效图片文字识别》这篇文章主要为大家详细介绍了一款基于微信OCR引擎的图片文字识别桌面应用开发全过程,可以实现从图片拖拽识别到文字提取,感兴趣的小伙伴可以跟随小编一... 目录一、项目概述1.1 开发背景1.2 技术选型1.3 核心优势二、功能详解2.1 核心功能模块2.

python编写朋克风格的天气查询程序

《python编写朋克风格的天气查询程序》这篇文章主要为大家详细介绍了一个基于Python的桌面应用程序,使用了tkinter库来创建图形用户界面并通过requests库调用Open-MeteoAPI... 目录工具介绍工具使用说明python脚本内容如何运行脚本工具介绍这个天气查询工具是一个基于 Pyt

Ubuntu设置程序开机自启动的操作步骤

《Ubuntu设置程序开机自启动的操作步骤》在部署程序到边缘端时,我们总希望可以通电即启动我们写好的程序,本篇博客用以记录如何在ubuntu开机执行某条命令或者某个可执行程序,需要的朋友可以参考下... 目录1、概述2、图形界面设置3、设置为Systemd服务1、概述测试环境:Ubuntu22.04 带图

IDEA如何实现远程断点调试jar包

《IDEA如何实现远程断点调试jar包》:本文主要介绍IDEA如何实现远程断点调试jar包的问题,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录问题步骤总结问题以jar包的形式运行Spring Boot项目时报错,但是在IDEA开发环境javascript下编译

Python程序打包exe,单文件和多文件方式

《Python程序打包exe,单文件和多文件方式》:本文主要介绍Python程序打包exe,单文件和多文件方式,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录python 脚本打成exe文件安装Pyinstaller准备一个ico图标打包方式一(适用于文件较少的程

MySQL 存储引擎 MyISAM详解(最新推荐)

《MySQL存储引擎MyISAM详解(最新推荐)》使用MyISAM存储引擎的表占用空间很小,但是由于使用表级锁定,所以限制了读/写操作的性能,通常用于中小型的Web应用和数据仓库配置中的只读或主要... 目录mysql 5.5 之前默认的存储引擎️‍一、MyISAM 存储引擎的特性️‍二、MyISAM 的主

Python程序的文件头部声明小结

《Python程序的文件头部声明小结》在Python文件的顶部声明编码通常是必须的,尤其是在处理非ASCII字符时,下面就来介绍一下两种头部文件声明,具有一定的参考价值,感兴趣的可以了解一下... 目录一、# coding=utf-8二、#!/usr/bin/env python三、运行Python程序四、

无法启动此程序因为计算机丢失api-ms-win-core-path-l1-1-0.dll修复方案

《无法启动此程序因为计算机丢失api-ms-win-core-path-l1-1-0.dll修复方案》:本文主要介绍了无法启动此程序,详细内容请阅读本文,希望能对你有所帮助... 在计算机使用过程中,我们经常会遇到一些错误提示,其中之一就是"api-ms-win-core-path-l1-1-0.dll丢失