You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by "Marcio Silva (JIRA)" <ji...@apache.org> on 2012/09/26 19:39:08 UTC

[jira] [Created] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Marcio Silva created ACCUMULO-776:
-------------------------------------

             Summary: TimestampFilter should serialize start and end as longs in the IteratorSetting
                 Key: ACCUMULO-776
                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
             Project: Accumulo
          Issue Type: Bug
            Reporter: Marcio Silva
            Priority: Minor


Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.

This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}

Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Keith Turner (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13491151#comment-13491151 ] 

Keith Turner commented on ACCUMULO-776:
---------------------------------------

bq.  I don't think anything is being changed in how things are being stored in ZK. 

No, I think your initial comments were correct.  The date encoded string will be stored in zookeeper, not a long.   To be sure I ran a little test.

{code:java}

    IteratorSetting is = new IteratorSetting(21, TimestampFilter.class);
    TimestampFilter.setStart(is, System.currentTimeMillis(), false);
    TimestampFilter.setEnd(is, System.currentTimeMillis() + 10000, false);
    conn.tableOperations().attachIterator("foo", is);

    Iterable<Entry<String,String>> propsIter = conn.tableOperations().getProperties("foo");
    for (Entry<String,String> entry : propsIter) {
      if (entry.getKey().contains("Timestamp"))
        System.out.println(entry);
    }
{code}

This prints out the following :

{noformat}
table.iterator.majc.TimestampFilter.opt.start=20121106024224GMT
 .
 .
 .
{noformat}

I think if I had applied the patch, a long would be stored in ZK instead.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490924#comment-13490924 ] 

Billie Rinaldi commented on ACCUMULO-776:
-----------------------------------------

I guess the question is whether the following procedure returns the same timestamp on all systems regardless of timezone.  Before the patch, the tablet server would have executed this code, and after the patch the client executes this code.
{code:java}
SimpleDateFormat dateParser = new SimpleDateFormat("yyyyMMddHHmmssz");
dateParser.setTimeZone(TimeZone.getTimeZone("GMT"));
long timestamp = dateParser.parse(dateString).getTime();
{code}
This date format requires the timezone to be set explicitly, e.g. "19990101000000GMT".

The TimestampFilter static set methods have units tests that passed before and after the patch.  I added the test that Marcio suggested, and it works only after the patch is applied.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490933#comment-13490933 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

{quote} I guess the question is whether the following procedure returns the same timestamp on all systems regardless of timezone. Before the patch, the tablet server would have executed this code, and after the patch the client executes this code.
 SimpleDateFormat dateParser = new SimpleDateFormat("yyyyMMddHHmmssz");
 dateParser.setTimeZone(TimeZone.getTimeZone("GMT"));
 long timestamp = dateParser.parse(dateString).getTime();
{quote} 

As long as the time is always converted to the same timezone, then timezone issues are not a problem, I would say. I would say that's a non-issue.


bq. The TimestampFilter static set methods have units tests that passed before and after the patch. I added the test that Marcio suggested, and it works only after the patch is applied.

Which is fine, but we need a test where a TimestampFilter is set as the old storage format with validation that it can be successfully read with the revised Filter.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490985#comment-13490985 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

I'm not familiar with Facebook's use of version value. Do you have a resource I can read?
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490941#comment-13490941 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

I don't think it's that painful. Looking at the removed lines of the patch, it looks like the formatted date string was stored, which included the time zone info. If we just make the new system a Stringified long, with the assumption that everything is GMT (as enforced by the code), then we can handle backward compatibility for any entires that have non-digit characters in it.

But yes, I think you bring up a larger question of what date 253402300800001 is supposed to be. That's either microsecond based time or it's past 10,000 AD. While I have faith in our software, I'm not sure if humanity will be around that long...
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Billie Rinaldi updated ACCUMULO-776:
------------------------------------

    Attachment: ACCUMULO-776_1.4.patch
    
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 1.4.1
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>             Fix For: 1.5.0, 1.4.2
>
>         Attachments: ACCUMULO-776_1.4.patch, ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Hudson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13493309#comment-13493309 ] 

Hudson commented on ACCUMULO-776:
---------------------------------

Integrated in Accumulo-Trunk #544 (See [https://builds.apache.org/job/Accumulo-Trunk/544/])
    ACCUMULO-776 made timestamp filter support longs greater than max date - merged to trunk (Revision 1407162)

     Result = SUCCESS
billie : 
Files : 
* /accumulo/trunk
* /accumulo/trunk/assemble
* /accumulo/trunk/core
* /accumulo/trunk/core/src/main/java/org/apache/accumulo/core/iterators/user/TimestampFilter.java
* /accumulo/trunk/core/src/test/java/org/apache/accumulo/core/iterators/user/FilterTest.java
* /accumulo/trunk/core/src/test/java/org/apache/accumulo/core/iterators/user/RegExFilterTest.java
* /accumulo/trunk/fate/src/main/java/org/apache/accumulo/fate/ZooStore.java
* /accumulo/trunk/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooSession.java
* /accumulo/trunk/server
* /accumulo/trunk/src

                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 1.4.1
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>             Fix For: 1.5.0, 1.4.2
>
>         Attachments: ACCUMULO-776_1.4.patch, ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Reopened] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Billie Rinaldi reopened ACCUMULO-776:
-------------------------------------


Keith pointed out there would still be issues with 1.4 compatibility, but that fast failing (client-side) for 1.4 would be helpful.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 1.4.1
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>             Fix For: 1.5.0, 1.4.2
>
>         Attachments: ACCUMULO-776_1.4.patch, ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Billie Rinaldi updated ACCUMULO-776:
------------------------------------

          Component/s: client
    Affects Version/s: 1.4.1
        Fix Version/s: 1.4.2
                       1.5.0

Committed patch with additional testing for validateOptions (which was good because I found and fixed an issue with it).
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 1.4.1
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>             Fix For: 1.5.0, 1.4.2
>
>         Attachments: ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13491122#comment-13491122 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

Interesting, that's a neat application of the visibilities.

I looked over the patch again, and I'm wondering if we have a compatability issue after all. I don't think anything is being changed in how things are being stored in ZK. So the only issue is the wire compatability which Keith mentioned before, which is nowhere as severe of an issue IMO.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Billie Rinaldi updated ACCUMULO-776:
------------------------------------

    Attachment: ACCUMULO-776.patch

Do people think I should apply this patch to the 1.4 branch, or just to trunk?
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490959#comment-13490959 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

Agreed, just integrate some sort of versioning into the format. Especially useful if we, for some reason, need to do this again.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Marcio Silva (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490982#comment-13490982 ] 

Marcio Silva commented on ACCUMULO-776:
---------------------------------------

bq. Did this ticket get opened because someone needed a year >= 10000

This issue is problematic for use-cases where the version value is being used to store a different concept than the epoch time (e.g. Facebook's use of the version value in HBase in their inbox search application).
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13491176#comment-13491176 ] 

Billie Rinaldi commented on ACCUMULO-776:
-----------------------------------------

bq. I think if I had applied the patch, a long would be stored in ZK instead.

Yes, that's right.  I like the idea of making it understand both by prefixing the long with LONG.  I'll try that out.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Keith Turner (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13492657#comment-13492657 ] 

Keith Turner commented on ACCUMULO-776:
---------------------------------------

I think the latest patch looks good.  The changes to validateOptions() are not tested by the unit test, but that method was not tested before.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Keith Turner (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490927#comment-13490927 ] 

Keith Turner commented on ACCUMULO-776:
---------------------------------------

bq. Well, regardless of version you need backwards compatibility. We don't want things from suddenly break for users because they upgraded and were using a TimestampFilter as a configured iterator.

Oh right, I totally spaced on that.  I was only thinking of using it as scan time iterator, because that the only way I have used it.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490923#comment-13490923 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

Well, regardless of version you need backwards compatibility. We don't want things from suddenly break for users because they upgraded and were using a TimestampFilter as a configured iterator.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490925#comment-13490925 ] 

Billie Rinaldi commented on ACCUMULO-776:
-----------------------------------------

Good point about running different client and server code.  That makes me think we should only make the change in trunk.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13492670#comment-13492670 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

bq. I think the latest patch looks good. The changes to validateOptions() are not tested by the unit test, but that method was not tested before.

Agreed
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Keith Turner (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490946#comment-13490946 ] 

Keith Turner commented on ACCUMULO-776:
---------------------------------------

bq. Yikes, does that mean we'd have to include timestamp format conversion for configured TimestampFilters in our upgrade from 1.4 to 1.5?
This could be done in the TimestampFilter code that reads the config rather than as part of the upgrade process.  I think we can identify the old persistent format because it ends with alpha chars and distinguish that from the new format which all numeric chars?  Unless there is a completely numeric timezone?  

bq.   Did this ticket get opened because someone needed a year >= 10000?
I suppose any long is valid in the timestamp, so the filter should probably handle it.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Keith Turner (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490955#comment-13490955 ] 

Keith Turner commented on ACCUMULO-776:
---------------------------------------

I suppose we can serialize the new persistent format however we want.  For example we could prefix it with LONG inorder to preclude any ambiguity with the old persistent format.  We could also use a different option name, but then would need to handle the case where the old and new option exists.  So to simplify I would rather the current option support two different persistent formats.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490934#comment-13490934 ] 

Billie Rinaldi commented on ACCUMULO-776:
-----------------------------------------

Yikes, does that mean we'd have to include timestamp format conversion for configured TimestampFilters in our upgrade from 1.4 to 1.5?

What if we just limited the max timestamp to years less than 10000 and threw an error when you tried to set a larger timestamp (instead of just erroring out on the server, like it does now)?  Did this ticket get opened because someone needed a year >= 10000?
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Comment Edited] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490941#comment-13490941 ] 

John Vines edited comment on ACCUMULO-776 at 11/5/12 9:36 PM:
--------------------------------------------------------------

I think you bring up a larger question of what date 253402300800001 is supposed to be. That's either microsecond based time or it's past 10,000 AD. While I have faith in our software, I'm not sure if humanity will be around that long...
                
      was (Author: vines):
    I don't think it's that painful. Looking at the removed lines of the patch, it looks like the formatted date string was stored, which included the time zone info. If we just make the new system a Stringified long, with the assumption that everything is GMT (as enforced by the code), then we can handle backward compatibility for any entires that have non-digit characters in it.

But yes, I think you bring up a larger question of what date 253402300800001 is supposed to be. That's either microsecond based time or it's past 10,000 AD. While I have faith in our software, I'm not sure if humanity will be around that long...
                  
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Marcio Silva (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13491108#comment-13491108 ] 

Marcio Silva commented on ACCUMULO-776:
---------------------------------------

It's described briefly on page 374 of Lars George's [HBase: The Definitive Guide|http://www.hbasebook.com/] and the schema used for inbox search is also described in this slide deck from QCon London [HBase @ Facebook|http://qconlondon.com/dl/qcon-london-2011/slides/KannanMuthukkaruppan_HBaseFacebook.pdf]

The basic idea is they build per-user search indices in a single HBase row using the version to store the message ids.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Assigned] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Billie Rinaldi reassigned ACCUMULO-776:
---------------------------------------

    Assignee: Billie Rinaldi
    
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Billie Rinaldi updated ACCUMULO-776:
------------------------------------

    Fix Version/s:     (was: 1.4.2)
                   1.4.3
    
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 1.4.1
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>             Fix For: 1.5.0, 1.4.3
>
>         Attachments: ACCUMULO-776_1.4.patch, ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490911#comment-13490911 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

Patch was smaller than I thought. I have no issues with a proper patch being rolled into 1.4.x, but we need to have backwards compatibility with the old system for both 1.4.x and 1.5.0. My other issue from the comment above about time zones still stands as well.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Billie Rinaldi updated ACCUMULO-776:
------------------------------------

    Attachment: ACCUMULO-776.patch

Updated patch with support for both option types.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Resolved] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Billie Rinaldi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Billie Rinaldi resolved ACCUMULO-776.
-------------------------------------

    Resolution: Fixed
    
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 1.4.1
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>             Fix For: 1.5.0, 1.4.2
>
>         Attachments: ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490909#comment-13490909 ] 

John Vines commented on ACCUMULO-776:
-------------------------------------

I'm concerned about the implications of the transition, regardless of version. Not having viewed, does this patch handle backwards compatability?

On a higher level about this ticket though, one of the reasons we used a formated Date is to prevent issues of clients and servers being in different timezone configurations, particularly the client and the actual server. Again, not having viewed the patch, I do not know if there is anything done here to handle it, but there needs to be some sort of consideration here.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Keith Turner (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490920#comment-13490920 ] 

Keith Turner commented on ACCUMULO-776:
---------------------------------------

I agree with John, if patched into 1.4 need to handle  backwards compatability in some way.  For example if someone is running a 1.4.1 client against a 1.4.3 server with this bug fix.  May not be as much of an issue for 1.5, since a 1.4 client and 1.5 server probably will not talk to each other.
                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>         Attachments: ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (ACCUMULO-776) TimestampFilter should serialize start and end as longs in the IteratorSetting

Posted by "Hudson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13493310#comment-13493310 ] 

Hudson commented on ACCUMULO-776:
---------------------------------

Integrated in Accumulo-1.4.x #247 (See [https://builds.apache.org/job/Accumulo-1.4.x/247/])
    ACCUMULO-776 reverted 1.4 changes to timestamp filter (Revision 1407165)
ACCUMULO-776 made timestamp filter support longs greater than max date (Revision 1407157)

     Result = SUCCESS
billie : 
Files : 
* /accumulo/branches/1.4/src/core/src/main/java/org/apache/accumulo/core/iterators/user/TimestampFilter.java
* /accumulo/branches/1.4/src/core/src/test/java/org/apache/accumulo/core/iterators/user/FilterTest.java

billie : 
Files : 
* /accumulo/branches/1.4/conf
* /accumulo/branches/1.4/src/core/src/main/java/org/apache/accumulo/core/iterators/user/TimestampFilter.java
* /accumulo/branches/1.4/src/core/src/test/java/org/apache/accumulo/core/iterators/user/FilterTest.java
* /accumulo/branches/1.4/src/core/src/test/java/org/apache/accumulo/core/iterators/user/RegExFilterTest.java

                
> TimestampFilter should serialize start and end as longs in the IteratorSetting
> ------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-776
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-776
>             Project: Accumulo
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 1.4.1
>            Reporter: Marcio Silva
>            Assignee: Billie Rinaldi
>            Priority: Minor
>             Fix For: 1.5.0, 1.4.2
>
>         Attachments: ACCUMULO-776_1.4.patch, ACCUMULO-776.patch, ACCUMULO-776.patch
>
>
> Although the TimestampFilter supports using longs to set the start or end timestamp, it formats them as strings using SimpleDateFormat when storing or retrieving them in the IteratorSetting.
> This results in exceptions when the timestamps being used aren't able to be formatted as _yyyyMMddHHmmssz_. For example, try {{setEnd(253402300800001,true)}}
> Instead, {{setStart()}} and {{setEnd()}} could just as easily use {{String.valueOf(long i)}} to store the values, and {{init()}} could retrieve them using {{Long.valueOf(String s)}}.  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira