accumulo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William Slacum (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ACCUMULO-2589) Create new client API
Date Fri, 01 May 2015 00:57:07 GMT

    [ https://issues.apache.org/jira/browse/ACCUMULO-2589?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14522577#comment-14522577
] 

William Slacum commented on ACCUMULO-2589:
------------------------------------------

TimeUnit is ok, but not as expressive as it loses the units for a value. For instance, if
I wanted to represent 10 seconds, I'd can do either:

{code}
Amount<Long, Time.SECONDS> duration = Amount.of(10L, Time.SECONDS);

long duration = TimeUnit.SECONDS.toSeconds(10L);
{code}
 
As a consequence methods can specify a unit in the type, so I could never pass a value that
represented seconds into a method that expected milliseconds without an explicit conversion.

The other thing is there's already a definition for things like bytes (so a {{BatchWriter}}'s
buffer size could then be expressed in bytes/kilobytes/megabytes), so it's got that when compared
to TimeUnit.

I'd think we would want to extract the Amount package from the library, since as a whole there's
other stuff we'd probably never use (and some stuff that might be useful, like Thrift decorators).
This should be feasible since it's ASLv2 licensed.

> Create new client API
> ---------------------
>
>                 Key: ACCUMULO-2589
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-2589
>             Project: Accumulo
>          Issue Type: New Feature
>          Components: client
>            Reporter: Christopher Tubbs
>            Assignee: Christopher Tubbs
>            Priority: Blocker
>             Fix For: 2.0.0
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> There are many issues with the current client API, and we've had a lot of lessons learned
that could be incorporated into a new one.
> Some of the issues this would address:
> * questions like "What is considered 'Public API'?"
> * automated testing for incompatible API changes
> * provide better support for alternative implementations of pluggable features
> * distinguish between compile-time dependencies and runtime dependencies
> * consistent exception handling
> * consistent/symmetric getters/setters
> * well-defined resource lifecycles
> * better resource management
> * simpler entry point to communicate with Accumulo
> * better support for client-side configuration management
> * logical layout of first class Accumulo objects in the API (Table, User, Scan, Connection)
> Some of these goal may evolve during the development of this feature, and many previously
identified issues can be moved to sub-tasks of this one. This ticket is intended to cover
the overall feature, but the details will be handled in sub-tasks.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message