You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@cassandra.apache.org by Shawna Qian <sh...@yahoo-inc.com> on 2012/05/08 00:00:44 UTC
using the proxy on the cli or configHelper to connect to cassandra
server
Hello:
In our cassandra settings, we need to specify the proxy to access the
cassandra: if using the java code, it will be like this:
Proxy proxy = new Proxy(Proxy.Type.SOCKS, new
InetSocketAddress("socks.corp.yahoo.com", 1080));
Socket socket = new Socket (proxy);
socket.connect(new InetSocketAddress(cassieHostName, cassiePort));
TSocket tsokect = new TSocket(socket);
TTransport tr = new TFramedTransport(tsokect);
But I am not sure how to specify this in the cassandra-cli. Also if I use
configHelper in hadoop jobs, how can I specify the proxy information?
Thx
Shawna
Re: using the proxy on the cli or configHelper to connect to cassandra server
Posted by aaron morton <aa...@thelastpickle.com>.
There is no support in the cli for using a socks proxy. You would need to add it.
Take a look in CliMain.java
Cheers
-----------------
Aaron Morton
Freelance Developer
@aaronmorton
http://www.thelastpickle.com
On 8/05/2012, at 10:00 AM, Shawna Qian wrote:
> Hello:
>
> In our cassandra settings, we need to specify the proxy to access the
> cassandra: if using the java code, it will be like this:
>
> Proxy proxy = new Proxy(Proxy.Type.SOCKS, new
> InetSocketAddress("socks.corp.yahoo.com", 1080));
> Socket socket = new Socket (proxy);
> socket.connect(new InetSocketAddress(cassieHostName, cassiePort));
> TSocket tsokect = new TSocket(socket);
> TTransport tr = new TFramedTransport(tsokect);
>
>
> But I am not sure how to specify this in the cassandra-cli. Also if I use
> configHelper in hadoop jobs, how can I specify the proxy information?
>
> Thx
> Shawna
>