GenericTicketConnectorSOAP not working as expected

Moderator: crythias

Post Reply
possebon
OTRS newbie
Posts: 29
Joined: 25 Sep 2014, 20:03
OTRS Version?: 6.0.15

GenericTicketConnectorSOAP not working as expected

Post by possebon » 13 Feb 2019, 00:20

Hi,

I'm running the OTRS 6.0.15 (on 6.0.5 version occurs the same) on CentOS 7, Apache 2.4.6.

Since all my HTTP and HTTPS traffic goes through a nginx reverse proxy, I configured my OTRS to get rid of "/otrs" on URL. I followed this link
viewtopic.php?t=9329

I'm able to login and use the Agent portal and the customer portal with success.

I need to use the GenericTicketConnectorSOAP then I downloaded the https://github.com/OTRS/otrs/blob/rel-6 ... orSOAP.yml and imported in my OTRS.

When I try to create a session using the Webservice, I have the following error message:

Code: Select all

otrs.client.BadStatusLineError: BadStatusLine Exception when trying to reach http://mydomain.com/nph-genericinterface.pl/Webservice/otrs/nph-genericinterface.pl/Webservice/GenericTicketConnectorSOAP.
            Are you using the correct webservice name?
I'm using the python-otrs (I already used it for years in another OTRS server, but 5.0 version)

The webservice URI I'm passing is: otrs_server_uri = r'http://mydomain.com/nph-genericinterface.pl/Webservice/'

The ScriptAlias at System Config is set to blank

At Apache Logs, I see this request:

Code: Select all

"POST /nph-genericinterface.pl/Webservice/otrs/nph-genericinterface.pl/Webservice/GenericTicketConnectorSOAP HTTP/1.1" 200
For some reason the "otrs/nph-genericinterface.pl/Webservice" is being appended and I can't figure out what is wrong.

Any help on this is very welcome.

Thanks in advance and best regards.

possebon
OTRS newbie
Posts: 29
Joined: 25 Sep 2014, 20:03
OTRS Version?: 6.0.15

Re: GenericTicketConnectorSOAP not working as expected

Post by possebon » 13 Feb 2019, 02:21

Additional information, when I use the following code, it works fine:

Code: Select all

otrs_login = 'agent'
otrs_password = 'password'


otrs_server_uri = r'http://10.193.28.54/'
webservice_name = 'GenericTicketConnectorSOAP'
otrs_client = GenericInterfaceClient(
    otrs_server_uri, tc=GenericTicketConnectorSOAP(webservice_name))

# user session
otrs_client.tc.SessionCreate(user_login=otrs_login, password=otrs_password)

On Apache log I have this

Code: Select all

10.193.28.54 - - [12/Feb/2019:22:14:41 -0200] "POST /otrs/nph-genericinterface.pl/Webservice/GenericTicketConnectorSOAP HTTP/1.1" 200 642
I suspect that there is something fixed on OTRS code that append the suffix "/otrs/nph-genericinterface.pl/Webservice" since I don't inform that on otrs_server_uri

reneeb
OTRS guru
Posts: 4795
Joined: 13 Mar 2011, 09:54
OTRS Version?: 3.3.x
Company: Perl-Services.de
Contact:

Re: GenericTicketConnectorSOAP not working as expected

Post by reneeb » 13 Feb 2019, 11:40

Perl / OTRS development: http://perl-services.de
Free OTRS add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de

possebon
OTRS newbie
Posts: 29
Joined: 25 Sep 2014, 20:03
OTRS Version?: 6.0.15

Re: GenericTicketConnectorSOAP not working as expected

Post by possebon » 13 Feb 2019, 14:52

Humm, this is strange, because I have on another server with OTRS 5 running exactly the same code.

I'm not sure about the same version o python-otrs, I'll check it out and post here.

Thanks reneeb for your comment.

possebon
OTRS newbie
Posts: 29
Joined: 25 Sep 2014, 20:03
OTRS Version?: 6.0.15

Re: GenericTicketConnectorSOAP not working as expected

Post by possebon » 13 Feb 2019, 15:01

I confirm that versions of python-otrs are different.

The version that is working in all scenarios 0.3.0 and the version that I posted is 0.4.3 the one that is joining the suffix.

Thanks again reneeb now it's clear what is going on.

I'll open an issue on python-otrs project because this is very limiting.

Best regards,

Post Reply