发布客户化PLSQL APIs到Oracle Integration Repositoy(IREP)
来源:互联网 发布:erp软件的作用 编辑:程序博客网 时间:2024/04/28 22:01
转:http://blog.csdn.net/cunxiyuan108/article/details/7752557
在Oracle EBS二次开发中,PL/SQL程序是开发人员使用频率最高的开发语言,同时也是大家最容易掌握的工具之一了,而我们也很希望将自己编写的PL/SQL程序发布为Web服务来提供给客户端程序使用,同时也可以实现和外围系统的集成,有了irep_parser这个工具,我们就可以将自己编写的PL/SQL程序发布到Oracle Integration Repositoy中。Oracle Integration Repositoy中集成接口的来源都是Oracle,客户化的程序发布上去的为Custom:
下面描述如何将PL/SQL程序接口发布到Oracle Integration Repositoy中作为集成接口供第三方程序集成调用
一、添加客户化应用到Product Family
客户化应用设置好之后,它没有归属于任何的产品家族,如我的客户化应用XHU,因此发布在客户化应用下的集成接口在Oracle Integration Repositoy中无法方便的查看,如下图:
如果客户化集成接口是组织到自己的应用下就需要先注册一个产品家族,下面将Hand University(XHU) 应用注册到Oracle Seeker Suite(os_pf)这个产品家族下作为例子进行演示:
1,添加产品家族 Oracle Seeker Suite(os_pf)
执行如下的SQL代码
123456789101112131415
begin -- Call the procedure ad_pa_insert_package.insert_ad_pm_product_info(x_product_abbreviation => 'os_pf', x_pseudo_product_flag => 'N', x_product_family_flag => 'Y', x_application_short_name => NULL, x_product_name => 'Oracle Seeker Suite', x_product_family_abbreviation => NULL, x_product_family_name => NULL, x_aru_update_date => SYSDATE, x_currdate => SYSDATE, x_last_updated_by => -1, x_created_by => -1); COMMIT;end;
2,注册Hand University(xhu)应用到产品家族中
执行如下的SQL代码
123456789101112131415
begin -- Call the procedure ad_pa_insert_package.insert_ad_pm_product_info(x_product_abbreviation => 'xhu', x_pseudo_product_flag => 'N', x_product_family_flag => 'N', x_application_short_name => 'XHU', x_product_name => 'Hand University', x_product_family_abbreviation => NULL, x_product_family_name => NULL, x_aru_update_date => SYSDATE, x_currdate => SYSDATE, x_last_updated_by => -1, x_created_by => -1); COMMIT;end;
3,关联Hand University应用到产品家族Oracle Seeker Suite下
执行如下的SQL代码
12345678910
begin -- Call the procedure ad_pa_insert_package.insert_ad_pm_prod_family_map(x_product_abbreviation => 'xhu', x_product_family_abbreviation => 'os_pf', x_aru_update_date => SYSDATE, x_currdate => SYSDATE, x_last_updated_by => -1, x_created_by => -1); COMMIT;end;
完成后如果应用下有集成接口可以看到如下的产品家族信息:
二、按照集成接口标记规范编写PL/SQL程序
按照业务逻辑的要求编写PL/SQL程序,除了需要在PL/SQL程序的声明中按照集成接口标记的要求添加标记注释之外,其它和一般的程序没有任何区别,如下是一个用来实现新增一个员工的程序:
1234567891011121314151617181920212223242526272829303132333435
CREATE OR REPLACE PACKAGE oracleseeker_emp_pkg AS/* $Header: $ *//*#* This package using maintain the employee information* @rep:scope public* @rep:product XHU* @rep:lifecycle active* @rep:displayname OracleSeeker Employee* @rep:compatibility S* @rep:category BUSINESS_ENTITY ORACLESEEKER*/ /*#* Create an Employee* @param p_empno employee number* @param p_ename employee name * @param p_job employee's job* @param p_mgr employee's manager* @param p_hiredate employee is hired date* @param p_sal employee's salary* @param p_comm employee's commision* @param p_deptno employee's department* @rep:scope public* @rep:lifecycle active* @rep:displayname Create an Employee*/ PROCEDURE create_employee( p_empno VARCHAR2, p_ename VARCHAR2, p_job VARCHAR2, p_mgr NUMBER, p_hiredate DATE, p_sal NUMBER, p_comm NUMBER, p_deptno NUMBER );END oracleseeker_emp_pkg ;
关键几个标记描述:
@rep:product XHU 代表集成接口注册到XHU应用中,必须是系统中存在的应用简称
@rep:displayname OracleSeeker Employee 集成接口的名称
@param 存储过程和方法的参数,都需要标注出来供调用服务的客户端查看
@rep:category BUSINESS_ENTITY ORACLESEEKER 业务实体的类型,ORACLESEEKER必须在BUSINESS_ENTITY 值列表类型下定义存在,否则无法通过验证
更多关于集成接口标记内容可以查看Oracle EBS Integrated SOA Gateway的实施手册。
三、验证集成接口标记并生成iLDT文件
将编写好的PLSQL声明定义保存为.pls文件(oracleseeker_emp_pkg.pls),并将其上传到服务器应用(xhu)的patch/115/sql目录下,通过Telnet使用命令来验证和生成集成接口标记文件,成功验证后会有如下的日志生成,同时会生成iLDT文件oracleseeker_emp_pkg_pls.ildt ,如果标记存在问题会打印出对应的错误信息,需要注意查看错误消息并进行修正。
1234567891011
[appl02@ebs006 irep]$ $IAS_ORACLE_HOME/perl/bin/perl $FND_TOP/bin/irep_parser.pl -g -v -username=sysadmin xhu:patch/115/sql:oracleseeker_emp_pkg.pls:12.0=oracleseeker_emp_pkg.pls# Interface Repository Annotation Processor, 12.0.0 # # Generating annotation output.# Processing file 'oracleseeker_emp_pkg.pls'.# Using YAPP-based parser.# Found a package-level annotation for 'ORACLESEEKER_EMP_PKG'.# Found a detail-level annotation...# Found a procedure named 'CREATE_EMPLOYEE'.# Done all files.
四、将iLDT文件上传到Oracle Integration Repositoy中
将上面生成的iLDT文件通过FNDLOAD命令工具上传到Oracle Integration Repositoy中,命令如下:
FNDLOAD apps/apps 0 Y UPLOAD $FND_TOP/patch/115/import/wfirep.lct oracleseeker_emp_pkg_pls.ildt
成功上传之后通过Oracle Integration Repositoy可以查看如下的集成接口信息
下面是接口中的详细描述
后面将讲解如何发布其它类型的程序到Oracle Integration Repositoy中,以及如何将发布后的集成接口转换为Web服务,并通过程序来调用它们。
- 发布客户化PLSQL APIs到Oracle Integration Repositoy(IREP)
- 发布客户化PLSQL APIs到Oracle Integration Repositoy(IREP)
- 发布客户化PLSQL APIs到Oracle Integration Repositoy(IREP)
- Oracle Integration Repositoy(IREP)中发布客户化集成接口为Web Service
- 发布PL/SQL API成Webservice,并注册到IR(Oracle Integration Repositoy)中
- 发布PL/SQL API成Webservice,并注册到IR(Oracle Integration Repositoy)中
- 使用Integration Repositoy Parser(IREP)的前提设置
- IREP: 测试Integration Repository客户化Web服务的调用
- 服务器vs及plsql运行正常,发布到IIS后连不上oracle数据库
- IREP: 发布并发程序(Concurrent Program)为Web服务
- IREP: 发布并发程序(Concurrent Program)为Web服务
- 从客户端PLSQL连接到ORACLE服务器
- 从客户端PLSQL连接到ORACLE服务器
- 从客户端PLSQL连接到ORACLE服务器
- PLSQL软件连接到Oracle客户端
- PLSQL Developer连接到远程Oracle服务器
- Excel数据通过plsql 导入到Oracle
- Excel数据通过plsql导入到Oracle
- css的display:inline-block
- pc移动端自适应布局js脚本(一)
- 矩阵求导公式
- 回调方法举例
- tensorflow学习笔记三:实例数据下载与读取
- 发布客户化PLSQL APIs到Oracle Integration Repositoy(IREP)
- 一些常用的正则
- 委托中的invoke和begininvoke
- DOCKER windows安装
- Javascript 严格模式use strict详解
- Django-Rest-Framework 入门
- 论文笔记 FCN: Fully Convolutional Networks for Semantic Segmentation
- 9 接口描述语言 slice
- IDEA运行web工程报错,Error running wis-client-web: SSL HTTP Connector node not found: set up one in the ser