hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Purtell <apurt...@apache.org>
Subject Re: About URL character escape in HBase Rest Servlet
Date Thu, 25 Mar 2010 15:59:29 GMT

> I'm using hadoop 0.20.1 and hbase 0.20.3. I have stargate
> running in tomcat and use apache as a proxy
> But here is the problem.
> Some of my row key have special character like '/'.

Can you provide more detail? Anything in the Stargate log? Or Tomcat log? Or Apache log?

We have a simple unit test that checks this:

  public void testURLEncodedKey() throws IOException, JAXBException {
    String encodedKey = URLEncoder.encode("http://www.google.com/", 
    Response response;
    response = putValueXML(TABLE, encodedKey, COLUMN_1, VALUE_1);
    assertEquals(response.getCode(), 200);
    response = putValuePB(TABLE, encodedKey, COLUMN_2, VALUE_2);
    assertEquals(response.getCode(), 200);
    checkValuePB(TABLE, encodedKey, COLUMN_1, VALUE_1);
    checkValueXML(TABLE, encodedKey, COLUMN_2, VALUE_2);

The above test encodes '/' as %2F and passes. But this test hosts the Stargate servlet in
a Jetty container. It does not test what might happen with Tomcat and/or a httpd proxy. Without
more information it's hard to know what might be going on.

Best regards,

   - Andy


View raw message