1

我正在编写一个从 OBIEE Web 服务获取数据的脚本。以下显示了创建的正确肥皂信封,但我没有得到任何结果。

#!/usr/bin/perl
use warnings;
use strict;
use diagnostics;

use XML::Simple;
use Data::Dumper;
use Log::Log4perl;
use SOAP::Lite 0.65 +trace => 'debug';

#Initialize Logger
Log::Log4perl->init("log.conf");
my $logger = Log::Log4perl->get_logger();

my $outputFormat = "SAWRowsetData";
my $SQL = qq(sql);
my $sessionID = "session id";

my $soap = SOAP::Lite
->readable(1)
->uri('urn://oracle.bi.webservices/v6')
->proxy( 'http://host:port/analytics/saw.dll/wsdl/v6' );

my $serializer = $soap->serializer();
$serializer->register_ns("urn://oracle.bi.webservices/v6","sawsoap");

my $som = $soap->call('executeSQLQuery',
SOAP::Data->name('sawsoap:sql' => $SQL)->type('xsd:string'),
SOAP::Data->name('sawsoap:outputFormat' => $outputFormat)->type('sawso
ap:XMLQueryOutputFormat'),
SOAP::Data->name('sawsoap:executionOptions')->type('sawsoap:XMLQueryEx
ecutionOptions')->value(
    \SOAP::Data->value(
        SOAP::Data->name("sawsoap:async")->type("xsd:boolean")->va
ue("?"),
SOAP::Data->name("sawsoap:maxRowsPerPage")->type("xsd:int")->value("?"),
        SOAP::Data->name("sawsoap:refresh")->type("xsd:boolean")->
value("?"),
SOAP::Data->name("sawsoap:presentationInfo")->type("xsd:boolean")->value("?"),
SOAP::Data->name("sawsoap:type")->type("xsd:string")->value("?"))),
SOAP::Data->name('sawsoap:sessionID' => $sessionID)->type('xsd:string'));

$logger->info(Dumper $som);

这是它制作的肥皂信封,使用soapUI可以很好地工作

<soap:Envelope 
soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
xmlns:sawsoap="urn://oracle.bi.webservices/v6" 
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" 
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soap:Body>
<logon xmlns="urn://oracle.bi.webservices/v6">
  <sawsoap:name xsi:type="xsd:string">name</sawsoap:name>

  <sawsoap:password xsi:type="xsd:string">password</sawsoap:password>
</logon>
</soap:Body>
</soap:Envelope>

我检查了 OBIEE 服务器并没有看到请求。它正在生成正确的东西,但请求没有得到通过。非常感谢任何见解。

4

1 回答 1

0

该问题已通过使用代理端点解决。

于 2013-12-02T14:37:28.333 回答