Proxy connection refused

Asked by Adam Peterson

I've deployed net_oa_kt.zip to my zimbra instance. I've configured the config_template.xml file with my knowledgetree server, and left the allowed domains at *.

When I try and save an attachment to knowledgetree, I get an error that says TypeError: result.xml is null.

In doing some investigating, I saw that it was trying to call my knowledgetree url:

https://<my zimbra server>/service/proxy?target=http%3A%2F%2F<my knowledgetree server>%2Fktwebservice%2FKTWebService.php%3Fmethod%3Dget_document_types

The result of this is:

HTTP ERROR 500

Problem accessing /service/proxy. Reason:

    Connection refused

What do I need to do to resolve this?

I'm using Release 6.0.1_GA_1816.RHEL5_64_20090911174852

Question information

Language:
English Edit question
Status:
Expired
For:
KnowledgeTree Zimlet Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Chris Puttick (cputtick) said :
#1

We've not done testing with Zimbra 6, and the Alfresco Zimlet, from which a chunk of code was lifted, has been reported to have problems under 6. However...

http://www.zimbra.com/forums/zimlets/11283-proxy-service-alloweddomains.html

May well be your problem...

Revision history for this message
Xrickung (xrickung) said :
#2

Please let us know if you still have this problem.

Revision history for this message
Adam Peterson (adam-peterson) said :
#3

I'm on to other problems now.

If I try to save an attachment using the zimlet now, I get an error stating that it could not get the folder detail. Watching the http traffic, I see the following:

https://<my zimbra server/service/proxy?target=http%3A%2F%2F<my knowledgetree server>%2Fktwebservice%2FKTWebService.php%3Fmethod%3Dlogin%26password%3DJ<My knowledgetree password>%26username%3D<my knowledgetree username>

All of the information appears to be correct in the URL.

I get the following xml response:
<response>
<status_code>0</status_code>
<message/>
<results>hs4e5ab2vvsmfhd4g7koa6sd64</results>
</response>

Next, my computer sends the following:

https://<my zimbra server>/service/proxy?target=http%3A%2F%2F<my knowledgetree server>%2Fktwebservice%2FKTWebService.php%3Fmethod%3Dget_folder_detail_by_name%26session_id%3Dviof8nnq932s55qn443f3m29n0%26folder_name%3DDroppedDocuments%2F

I get the following xml response:

<response>
<message>API could not be authenticated: Session is invalid</message>
<status_code>1</status_code>
</response>

I've verified that the username and password I'm sending in the first URL is correct.

Revision history for this message
Xrickung (xrickung) said :
#4

It looks like kt session died before the zimlet made the second request.
Basically, the result of the first request (login) will be used as the session_id of every request after.

Can you manually make requests with the links below (in your web browser) and post the xml result?

#1
http://<yourknowledgetreeserver>/ktwebservice/KTWebService.php?method=login&password=<your knowledgetree password>&username=<your knowledgetree username>

#2
http://<yourknowledgetreeserver>/ktwebservice/KTWebService.php?method=get_folder_detail_by_name&session_id=<ResultOfTheFirstRequest>&folder_name=DroppedDocuments/

Revision history for this message
Adam Peterson (adam-peterson) said :
#5

on #1, I got

<response>
<status_code>0</status_code>
<message/>
<results>i6k6ptjmi31tdgu3to25dlgjp7</results>
</response>

#2:

<response>
<message>API could not be authenticated: Session is invalid</message>
<status_code>1</status_code>
</response>

Revision history for this message
Xrickung (xrickung) said :
#6

Hi Adam,

What KT and Zimbra version are you using? and Does this issue happen regularly?

Revision history for this message
Adam Peterson (adam-peterson) said :
#7

It happens regularly. I've never been able to use the plugin to save documents to knowledgetree.

I'm using Zimbra Release 6.0.1_GA_1816.RHEL5_64_20090911174852 CentOS5_64 FOSS edition

and

KnowledgeTree Version 3.6.1 (Community Edition)

Revision history for this message
Xrickung (xrickung) said :
#8

Unfortunately, I haven't tested it with the zimbra6 yet, so this could be a problem with the new zimbra API as I've seen a thread saying that Alfresco zimlet doesn't work neither.

Btw, I'll have a look and will inform you once it gets updated.

So sorry,
Porntep.

Revision history for this message
Xrickung (xrickung) said :
#9

I just noticed that you received the same error though making a request through web browser so I think this should be a problem with your KTserver not the zimlet.
http://wiki.knowledgetree.com/Open_Search#Invalid_Session_Response

Make sure you have entered the right session_id in the request.

Revision history for this message
Adam Peterson (adam-peterson) said :
#10

I now have my Knowledgetree session issue fixed. When I try the URL's you gave me earlier, I get

<response>
<status_code>0</status_code>
<message/>

<results>
<id>2</id>
<folder_name>DroppedDocuments</folder_name>
<parent_id>1</parent_id>
<full_path>DroppedDocuments</full_path>
<permissions>RWA</permissions>
</results>
</response>

I now get an error that says that a.xml is null when I try and save files from Zimbra. Zimbra now sends this URL:

https://<my zimbra server>/service/zimlet/net_oa_kt/knowledgetree.jsp?session_id=mitjlssfc0t9h8i2csvf810op6&document_name=adam1x1.jpg&action=A&uploadURL=http%3A%2F%2F<my knowledgetree server>%2Fktwebservice%2Fupload.php%3F&getURL=https%3A%2F%2F<my zimbra server>%2Fservice%2Fhome%2F~%2F%3Fauth%3Dco%26loc%3Den_US%26id%3D260%26part%3D2

I get the following response back:

HTTP ERROR 500

Problem accessing /service/zimlet/net_oa_kt/knowledgetree.jsp. Reason:

    PWC6033: Unable to compile class for JSP

PWC6199: Generated servlet error:
Only a type can be imported. com.zimbra.cs.util.NetUtil resolves to a package

PWC6199: Generated servlet error:
Only a type can be imported. com.zimbra.cs.servlet.ZimbraServlet resolves to a package

Thanks for your help.

Revision history for this message
parchavapong (xkung) said :
#11

There seems to be changes in jsp support on the version 6 and I've got the same problem when tested it last week but haven't got a chance to fix it yet.

Btw, have a look at this wiki and the thread below for the explanation.
http://wiki.zimbra.com/index.php?title=Zimlet_JSP

http://www.zimbra.com/forums/zimlets/34296-asterisk-pbx-integration-zimlet-zcs-6-a.html

Hope this help,
Porntep

Revision history for this message
Launchpad Janitor (janitor) said :
#12

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
sanil (sanil-liviatech) said :
#13

Hii all,
I have deployed a zimlet which makes a ajax request to my ruby on rails application. Im getting an error "connection Refused Probelm accessing service/proxy/". In the config_template.xml, i have defined the property to allow domains. Also on the zimbra server i ran the command the command needed to allow domians. But still im getting the same error.
Please Help:(
Sanil Naik.