Hi,

Problem solved.

I have used secure implementation and used the 'TSSLSocket' instead of
'TSocket' which implements the SSL implementation of client-side and
disabled SSL certificate validation.

Now events can be published to CEP and BAM with out any issue.

Thanks


On Tue, Jun 17, 2014 at 8:51 AM, Dinesh Bandara <[email protected]> wrote:

> Hi
>
> I have generated the python skeletons from files in [1] and tried to write
> a python client. When running the client following error occurred,
>
>   File "PythonClient.py", line 52, in <module>
>     client.connect('admin','admin')
>   File
> "gen-py/ThriftSecureEventTransmissionService/ThriftSecureEventTransmissionService.py",
> line 92, in connect
>     return self.recv_connect()
>   File
> "gen-py/ThriftSecureEventTransmissionService/ThriftSecureEventTransmissionService.py",
> line 104, in recv_connect
>     (fname, mtype, rseqid) = self._iprot.readMessageBegin()
>   File
> "/home/dinesh/cartridge-agent/examples/carbon/thrift/protocol/TBinaryProtocol.py",
> line 140, in readMessageBegin
>     name = self.trans.readAll(sz)
>   File
> "/home/dinesh/cartridge-agent/examples/carbon/thrift/transport/TTransport.py",
> line 58, in readAll
>     chunk = self.read(sz - have)
>   File
> "/home/dinesh/cartridge-agent/examples/carbon/thrift/transport/TTransport.py",
> line 159, in read
>     self.__rbuf = StringIO(self.__trans.read(max(sz, self.__rbuf_size)))
>   File
> "/home/dinesh/cartridge-agent/examples/carbon/thrift/transport/TSocket.py",
> line 118, in read
>     message='TSocket read 0 bytes')
> thrift.transport.TTransport.TTransportException: TSocket read 0 bytes
>
> Seems like the connect function could not be accessed.
>
> Any idea on this?
>
> [1]
> https://svn.wso2.org/repos/wso2/carbon/platform/branches/turing/components/data-bridge/org.wso2.carbon.databridge.commons.thrift/4.2.0/src/main/resources/
>
>
> Thanks
> --
> *Dinesh Bandara*
> Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
>


-- 
*Dinesh Bandara*
Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to