Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Commits on Jun 8, 2011
  1. @ingenthr

    Change a Bucket instance variable to final.

    ingenthr authored ingenthr committed
    Change-Id: I3d505cd6f16bf2b18571f36960f957acea31dabc
    Reviewed-on: http://review.couchbase.org/6868
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  2. @ingenthr

    Change ConfigType enum for clarity.

    ingenthr authored ingenthr committed
    The word CACHE is a bit too overloaded, even here.  Going to
    MEMCACHE will make things clearer, and so will more docs.
    
    Change-Id: Icace3e363bdab30b15df7e0f9946a8355fa02cc4
    Reviewed-on: http://review.couchbase.org/6867
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  3. @ingenthr

    Added logging for manipulation of nodesMap in VBucketLocator.

    ingenthr authored ingenthr committed
    Some situations have come up which are unexepctedly causing the
    nodesMap to return a null when identifying the primary for a given
    key.  We will now debug log how we build that map and look at the
    insides of the nodesMap if this situation occurs.
    
    Change-Id: Ia70079265863f17acdb93cc0115e8d43a8930e13
    Signed-off-by: Matt Ingenthron <ingenthr@cep.net>
    Reviewed-on: http://review.couchbase.org/6866
    Tested-by: Matt Ingenthron <matt@couchbase.com>
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
  4. @ingenthr

    Remove standard Authenticator and replace with simple auth header.

    ingenthr authored ingenthr committed
    It was found that the Authenticator was caching within the process
    in some cases and in others just plain wasn't working.  Since
    nothing more than HTTP Basic is required at the moment, just add
    our own header.
    
    Change-Id: I6bfce8ba7b51b76c8b99149405b0caadbe60816e
    Signed-off-by: Matt Ingenthron <ingenthr@cep.net>
    Reviewed-on: http://review.couchbase.org/6865
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  5. @ingenthr

    Extracted HTTP auth header to common place.

    ingenthr authored ingenthr committed
    Change-Id: I530cd25641cfebbb0aebfe13fd250c19a851f8be
    Signed-off-by: Matt Ingenthron <ingenthr@cep.net>
    Reviewed-on: http://review.couchbase.org/6864
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  6. @ingenthr

    Change client ctor to detect vbucket usage from server.

    ingenthr authored ingenthr committed
    The question about whether or not to use vbuckets is really a
    funciton of the type of configuration the server will hand out.
    There should be no reason to give a URI, bucket name and whether
    or not it's vbucket capable.  That should be discernable from the
    configuration supplied by the server.
    
    This is believed to be compatible with how moxi detects cache
    buckets from membase buckets.
    
    Change-Id: I640fefc37bc863bf5991aa84c6f9fc7e181f5660
    Reviewed-on: http://review.couchbase.org/6863
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  7. @ingenthr

    Allow config to handle cache as well.

    ingenthr authored ingenthr committed
    Change-Id: I245d89b98279a431008c47ac410c1f63d2ca2aac
    Reviewed-on: http://review.couchbase.org/6862
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  8. @ingenthr

    Add a ConfigType via an enum.

    ingenthr authored ingenthr committed
    Change-Id: I450402e9d56768378353ebcf77f7ad313093fddf
    Signed-off-by: Matt Ingenthron <ingenthr@cep.net>
    Reviewed-on: http://review.couchbase.org/6861
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  9. @ingenthr

    Refactor: not a collection of vbuckets, more of a configuration.

    ingenthr authored ingenthr committed
    Change-Id: Ie39c9799fe548c9ab5b01a7d278edab1b5d23aeb
    Reviewed-on: http://review.couchbase.org/6860
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  10. @ingenthr

    Added check for moxi when testing.

    ingenthr authored ingenthr committed
    Change-Id: Ifbd8d7863adc55f7c6cf31355c87df9a34f75389
    Signed-off-by: Matt Ingenthron <ingenthr@cep.net>
    Reviewed-on: http://review.couchbase.org/6859
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  11. @ingenthr

    Assert the node must exist when finding primary.

    ingenthr authored ingenthr committed
    Not everyone will have assertions on, but if they do the underlying
    cause of the confusing hostname or IP address lookup would have
    been caught here, rather than in a more confusing place.
    
    Change-Id: I8b8485fe1a1be15d377d39b7b4301024e8d8fd38
    Reviewed-on: http://review.couchbase.org/6858
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  12. @ingenthr

    Add both hostnames and IPs to the nodes map.

    ingenthr authored ingenthr committed
    Depending on the deployment environment and the configuration, we
    may see either an IP or a hostname from the REST interface.  To ensure
    we can look up the node later, simply add both to the internal Map.
    
    Change-Id: I390d889a67ac61523a0f5485f73cdeab0d768982
    Reviewed-on: http://review.couchbase.org/6857
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  13. @bairon @ingenthr

    Unit test and javadoc additions.

    bairon authored ingenthr committed
    Added javadocs for complex classes
    Added a test method to check the vbucket awareness
    
    Change-Id: I243ac1c2ff99bd81531fef5a46a2e94bd151dac7
    Reviewed-on: http://review.couchbase.org/6856
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  14. @bairon @ingenthr

    Bugfixing not_my_vbucket occurs on optimized set

    bairon authored ingenthr committed
    Setting correct vbucket index to the optimized set operation
    Added warn message if a not_my_vbucket occurs
    
    Change-Id: I0a1699e88f3ed6ec3d0dc8524ffb1d1c1853a86a
    Signed-off-by: Matt Ingenthron <ingenthr@cep.net>
    Reviewed-on: http://review.couchbase.org/6855
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  15. @bairon @ingenthr

    Bugfixing of NOT_MY_VBUCKET handling

    bairon authored ingenthr committed
    Added a collection of nodes that returned NOT_MY_VBUCKET to the operation.
    Changed OperationFactory clone method to copy that collection.
    Correct setting of NOT_MY_VBUCKET status for operation implementations.
    Added getAlternative method in node locator to be called in Retry case.
    Added unit test for getAlternative method
    
    Change-Id: I6c51f1407ebdd5858ffd9342113899c56473408e
    Reviewed-on: http://review.couchbase.org/6854
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  16. @mikewied @ingenthr

    Fixed .classpath file to include all dependencies

    mikewied authored ingenthr committed
    Change-Id: Ic729a3a12b05657bf338cbca0f5a9e173e71ce77
    Reviewed-on: http://review.couchbase.org/6853
    Tested-by: Michael Wiederhold <mike@couchbase.com>
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
  17. @ingenthr

    Set the status when receiving ERR_NOT_MY_VBUCKET.

    ingenthr authored ingenthr committed
    Change-Id: I572375de9f43de1da1a7681206decdf8fcc7f5fc
    Reviewed-on: http://review.couchbase.org/6816
    Reviewed-by: Michael Wiederhold <mike@couchbase.com>
    Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  18. @bairon @ingenthr

    Allow MemcachedClient and connections to be reconfigurable.

    bairon authored ingenthr committed
    Change-Id: I745ed511aac4af5fbc40244aa5cb8e607cf05f91
    Reviewed-on: http://review.couchbase.org/6815
    Tested-by: Michael Wiederhold <mike@couchbase.com>
    Reviewed-by: Michael Wiederhold <mike@couchbase.com>
  19. @bairon @ingenthr

    Added VbucketNodeLocator, keyed operation handling.

    bairon authored ingenthr committed
    Change-Id: I2a64540f6baa711f80af6e2419c30829c6876af8
    Reviewed-on: http://review.couchbase.org/6814
    Tested-by: Matt Ingenthron <matt@couchbase.com>
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
  20. @bairon @ingenthr

    Add a configuration provider for bucket updates.

    bairon authored ingenthr committed
    Change-Id: I202aa38d5c600f1e40febca02f303398a4600977
    Reviewed-on: http://review.couchbase.org/6760
    Reviewed-by: Michael Wiederhold <mike@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
  21. @bairon @ingenthr

    Added bucket monitor with response handler.

    bairon authored ingenthr committed
    This adds a Bucket monitor with a response handler based on the netty
    framework to read bucket's streaming channel. It passes the received
    configuration to registered observers.
    
    Change-Id: I92472a89f15b9fdbe9725f8a9a4abb2d645a591c
    Reviewed-on: http://review.couchbase.org/6674
    Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  22. @ingenthr

    If it is membase, do not test some things.

    ingenthr authored ingenthr committed
    Change-Id: I2fabbb02c298fd3d9c3b32c71d9b69b2a0123c7a
    Reviewed-on: http://review.couchbase.org/6673
    Reviewed-by: Dustin Sallings <dustin@spy.net>
    Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
    Reviewed-by: Michael Wiederhold <mike@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
  23. @bairon @ingenthr

    Added vbucket configuration parser from JSON.

    bairon authored ingenthr committed
    This parser from JSON has several methods for parsing JSON, beans to
    store configuration settings and unit tests.
    
    Change-Id: I478b274e7901e8c1729c20fcc29577b8aff651af
    Reviewed-on: http://review.couchbase.org/6672
    Reviewed-by: Michael Wiederhold <mike@couchbase.com>
    Tested-by: Matt Ingenthron <matt@couchbase.com>
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
Commits on Jun 7, 2011
  1. @mikewied @trondn

    Added Get And Touch Command

    mikewied authored trondn committed
    The get and touch operation  allows the user to get a keys
    value and reset its expiration. Unit tests will come later
    
    Change-Id: I3c65741325aaf979fa55043fb1f0d114e75c1471
    Reviewed-on: http://review.couchbase.org/6813
    Tested-by: Michael Wiederhold <mike@couchbase.com>
    Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
Commits on Jun 6, 2011
  1. @mikewied

    Added getl operation

    mikewied authored mikewied committed
    Getl works with both ascii and binary. Unit test will be added in a future commit
    but this code has been tested thoughly.
    
    Change-Id: I9859d8e3752c519bd0bcf67009a0a3999f5cbbf2
    Reviewed-on: http://review.couchbase.org/6778
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
    Tested-by: Michael Wiederhold <mike@couchbase.com>
Commits on Jun 4, 2011
  1. @mikewied

    Added touch operation

    mikewied authored mikewied committed
    Added an operation to reset the expiration time of a key. I have
    tested this code thoughly and will check in the unit tests in a
    later commit.
    
    Change-Id: Iee3045bdb58142dd44c9e8c723dffe7abdbcb230
    Reviewed-on: http://review.couchbase.org/6753
    Tested-by: Michael Wiederhold <mike@couchbase.com>
    Reviewed-by: Matt Ingenthron <matt@couchbase.com>
Commits on Jun 3, 2011
  1. @mikewied

    Added TEMP_FAIL handling to set operations

    mikewied authored committed
    TMP_FAIL is sent to the client when the server is out of memory.
    The current way of handling this error is to reconnect, but this
    is no the correct way to handle a this error since the server will
    be available soon.
    
    There are other commands that should handle this as well, but right
    now I am only submitting a fix for the set operation since this is
    the operration that causes this error most frequently. We plan on
    adding support for all known Membase commands in a future release.
    
    Change-Id: I8099dd7c85a45c81667e3a566995995dd3780b32
    Reviewed-on: http://review.couchbase.org/6751
    Tested-by: Michael Wiederhold <mike@membase.com>
    Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
    Reviewed-by: Dustin Sallings <dustin@spy.net>
  2. @bairon

    Integrated jvbucket

    bairon authored Michael Wiederhold committed
    Added jvbucket 1.0 classes to the project
    
    Change-Id: I8771917e47fd146a371ba33bed7b0ca31cfcbff1
    Reviewed-on: http://review.couchbase.org/6671
    Reviewed-by: Michael Wiederhold <mike@membase.com>
    Tested-by: Michael Wiederhold <mike@membase.com>
Commits on May 18, 2011
  1. @ingenthr

    Buildfile changes to support Maven 2 artifact upload.

    ingenthr authored committed
    This build file change slightly redefines the artifacts from
    memcached to spymemcached.  This feels right to me.
    
    I've tested the resulting upload with both NetBeans and Eclipse
    Maven support.  I can tell war stories later.
    
    Change-Id: Iee37db23f4a5d02328f8dc62253a87895857f59d
    Reviewed-on: http://review.membase.org/6208
    Tested-by: Matt Ingenthron <matt@couchbase.com>
    Reviewed-by: Dustin Sallings <dustin@spy.net>
Commits on May 11, 2011
  1. Removed a bit of dead test code.

    authored Matt Ingenthron committed
    Change-Id: I295d7b6b301217866f1074c526cdeba6d60420ab
    Reviewed-on: http://review.membase.org/6152
    Tested-by: Matt Ingenthron <matt@northscale.com>
    Reviewed-by: Matt Ingenthron <matt@northscale.com>
  2. Compilation fix after spring de-generification.

    authored Matt Ingenthron committed
    Change-Id: Ic3cddeedb76ce096569a34e3d8024be06bd4bd62
    Reviewed-on: http://review.membase.org/6151
    Tested-by: Matt Ingenthron <matt@northscale.com>
    Reviewed-by: Matt Ingenthron <matt@northscale.com>
  3. @lukelappin

    Do not use generics with Spring Factory Bean, be 2.5 compatible.

    lukelappin authored Matt Ingenthron committed
    To be backward compatible with Spring 2.5, the Factory Bean should
    avoid the use of generics.
    
    Change-Id: I2244a24a051b1b90e4142fa01785ae7e095ed87f
    Reviewed-on: http://review.membase.org/6091
    Reviewed-by: Michael Wiederhold <mike@membase.com>
    Reviewed-by: Nelz <nelz9999@gmail.com>
    Reviewed-by: Luke Lappin <lukelappin@gmail.com>
    Reviewed-by: Eran Harel <harel.eran@gmail.com>
    Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
    Reviewed-by: Dustin Sallings <dustin@spy.net>
    Tested-by: Matt Ingenthron <matt@northscale.com>
Commits on May 10, 2011
  1. @ingenthr

    Increase the maximum size allowed. Issue 106.

    ingenthr authored Matt Ingenthron committed
    Though memcached still has a 1MiB size by default (overridable
    with a flag), other engines may have their own maximum.  Membase
    for instance has a 20MiB maximum.
    
    Note that the size enforced by the transcoder can be overridden
    through it's ctor.  The reason for making this change is to
    create a new, larger default.
    
    At least for the remainder of the 2.6 series, rather than do
    deep surgery on this issue, just bump up the maximum.
    
    Change-Id: I3e7bb000b12a63b4a299cb8b79a3151fbfc91615
    Reviewed-on: http://review.membase.org/6074
    Reviewed-by: Michael Wiederhold <mike@membase.com>
    Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
    Tested-by: Matt Ingenthron <matt@northscale.com>
Commits on Apr 22, 2011
  1. @ingenthr

    Search more with the KetamaIterator.

    ingenthr authored Matt Ingenthron committed
    The existing KetamaIterator implementation, with a small number
    of nodes, may actually hit the same down node multiple times in
    a row leading to failing to find a node when it should find
    another one.
    
    The original libketama[1] hashes each server to 160 numeric
    values.  These are spread out in a 64-bit value.  The key is
    then hashed to a numeric value within that 64-bit value and
    walked forward until it finds a server.
    
    Previously, this library's ketama implementation would only look
    in the consistent hash for a number of iterations limited by the
    number of servers.  With two servers (similar to flipping a
    coin, you'd get heads twice in a row sometimes) you would have
    a 1 in 4 chance of picking the same dead server twice.
    
    The new implementation will iterate based on the number of
    servers, but attempts to keep the probability of hitting the
    same dead server to less than 1% for a two node configuration.
    This will guarantee less than 1% possibility with two or more
    servers.
    
    Because we iterate by simply appending the number of tries on
    the front of the key, we'll be quite random about where in
    the continuium we hit.  Each selection is rather random, but
    for a set of results already calculated, half of which are
    alive and half of which are dead, we can say that in seven
    iterations, there is only a 1/128 [1/(2^7)] chance that we
    would not select once at least one alive server.  The
    probability for any given test still 1/2, but we can describe
    the probability of the iterations.  The key info on this came
    from the "gambler's fallacy"[2].
    
    1. https://github.com/RJ/ketama/blob/master/libketama/ketama.c
    2. http://en.wikipedia.org/wiki/Gambler's_fallacy
    
    Other references:
    http://answers.google.com/answers/threadview/id/568615.html
    http://en.wikipedia.org/wiki/Combinations
    
    Change-Id: I6fa52c0b02516b68ca8da26e4fd85bb1730b82b2
    Reviewed-on: http://review.membase.org/5207
    Reviewed-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>
    Tested-by: Matt Ingenthron <matt@northscale.com>
  2. @ingenthr

    Separate the KetamaIterator for future dynamic configuration.

    ingenthr authored Matt Ingenthron committed
    Some future implementations may want to have dynamic changes to
    the nodes list, so the KetamaIterator has been refactored to its
    own class so it can be replaced while a client is instantiated.
    
    Change-Id: I0c8102bf737226c054662b043661ec97907a283b
    Reviewed-on: http://review.membase.org/5206
    Reviewed-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>
    Tested-by: Matt Ingenthron <matt@northscale.com>
Something went wrong with that request. Please try again.