Webservice 404

Use this forum for questions regarding adoption and functionality of OpenEMM

Moderator: moderator

tobiask
Posts: 4
Joined: Wed Apr 23, 2008 2:08 pm

Webservice 404

Post by tobiask »

Hi,

I downloaded and installed the VMX version (5.4). It worked well, the server is running in the local network at 192.168.100.127 and I can access the web interface.

I've set up the webservice as written in the documentation "OpenEMM Webservices 1.0.1" with the following command:
./EmmCreateWSDL.sh -o ws.wsdl -l "http://192.168.100.127:8080/webservices" -n "urn:agnitas-webservice" -w ALL org.agnitas.webservice.EmmWebService_Port

The local test-client worked well and gave some results.

I can access the webservice at http://192.168.100.127:8080/emm_webservice with the browser, the output is as following:
And now... Some Services
* urn:agnitas-webservice (wsdl)
o newEmailMailing
o insertContent
o deleteContent
o sendMailing
o addSubscriber
o getSubscriber
o findSubscriber
o deleteSubscriber
o setSubscriberBinding
o newEmailMailingWithReply
o updateEmailMailing
o getSubscriberBinding
The link of the wsdl file links to http://192.168.100.127:8080/services/ur ... rvice?wsdl .
Going to this url with the browser results in a 404.

I created a little PHP test script that I execute locally on a normal xampp installation:

Code: Select all

<?php
$wsdl = dirname(__FILE__).'/ws.wsdl';

$soapclient = new SoapClient($wsdl, array('trace' => 1));
$params = array('in0' => 'mailing','in1' => 'xxxxx', 'in2' => true, 'in3' => 'email', 'in4' => true, 'in5' => array('email'), 'in6' => array('test@testinguser.com'));
try {
  $res = $soapclient->__soapCall('addSubscriber', $params);
} catch (Exception $e) {
  var_dump($e);
}
var_dump($soapclient->__getLastResponseHeaders());
I also tried

Code: Select all

$res = $soapclient->addSubscriber('mailing','xxxxx',true, 'email',true,array('email'),array('test@testinguser.com'));
to call the method directly, with the same result.


The result is
object(SoapFault)#2 (8) {
["message:protected"]=>
string(9) "Not Found"
["string:private"]=>
string(0) ""
["code:protected"]=>
int(0)
["file:protected"]=>
string(32) "C:\xampp\htdocs\openemm\test.php"
["line:protected"]=>
int(9)
["trace:private"]=>
array(2) {
[0]=>
array(4) {
["function"]=>
string(11) "__doRequest"
["class"]=>
string(10) "SoapClient"
["type"]=>
string(2) "->"
["args"]=>
array(5) {
[0]=>
string(846) "<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:agnitas-webservice" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encodin ... riber><in0 xsi:type="SOAP-ENC:string">mailing</in0><in1 xsi:type="SOAP-ENC:string">xxxxxx</in1><in2 xsi:type="xsd:boolean">true</in2><in3 xsi:type="SOAP-ENC:string">email</in3><in4 xsi:type="xsd:boolean">true</in4><in5 xsi:type="ns1:StringArrayType"><x xsi:type="xsd:string">email</x></in5><in6 xsi:type="ns1:StringArrayType"><x xsi:type="xsd:string">test@testinguser.com</x></in6></ns1:addSubscriber></SOAP-ENV:Body></SOAP-ENV:Envelope>
"
[1]=>
string(39) "http://192.168.100.127:8080/webservices"
[2]=>
string(0) ""
[3]=>
int(1)
[4]=>
int(0)
}
}
[1]=>
array(6) {
["file"]=>
string(32) "C:\xampp\htdocs\openemm\test.php"
["line"]=>
int(9)
["function"]=>
string(10) "__soapCall"
["class"]=>
string(10) "SoapClient"
["type"]=>
string(2) "->"
["args"]=>
array(2) {
[0]=>
string(13) "addSubscriber"
[1]=>
array(7) {
["in0"]=>
string(9) "mailing"
["in1"]=>
string(7) "xxxxxx"
["in2"]=>
bool(true)
["in3"]=>
string(5) "email"
["in4"]=>
bool(true)
["in5"]=>
array(1) {
[0]=>
string(5) "email"
}
["in6"]=>
array(1) {
[0]=>
string(20) "test@testinguser.com"
}
}
}
}
}
["faultstring"]=>
string(9) "Not Found"
["faultcode"]=>
string(4) "HTTP"
}

string(151) "HTTP/1.1 404 Not Found
Server: Resin/3.0.19
Content-Type: text/html; charset=UTF-8
Transfer-Encoding: chunked
Date: Wed, 23 Apr 2008 16:54:08 GMT
"
Any clue what's wrong? What can I do to get this working? I guess as there are only a few postings in this forum regarding webservice 404 that the reason could be a misconfiguration. But since this is a "vanilla" VMware image, I don't know what.

Best regards,
Tobias