Commit 77e7f714 authored by Greg Williams's avatar Greg Williams
Browse files

Merged in develop

parents 0c0c9fe8 4d70586d
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -10,8 +10,9 @@ PUB_INC = ./include
#===============================================================================
CC ?= gcc
OPTIMIZE = -O3
SYSTEM_TEST_HOST ?= \"localhost\"
WARN = -Wall -Wextra -Wstrict-prototypes -Wcast-align -pedantic -Wno-missing-field-initializers -Werror=strict-prototypes
CDEFS += -D_POSIX_C_SOURCE=199309L -D_C99_SOURCE=1
CDEFS += -D_POSIX_C_SOURCE=199309L -D_C99_SOURCE=1 -DSYSTEM_TEST_HOST=${SYSTEM_TEST_HOST}
CFLAGS += -std=c99 -fPIC -g $(WARN) $(CDEFS) $(OPTIMIZE)
LDFLAGS += -lm -lcrypto -lssl -lpthread

+1 −0
Original line number Diff line number Diff line
@@ -4,6 +4,7 @@ compiler = ENV.fetch('CC', 'gcc')
compiler_location = `which #{compiler}`.strip
compiler_info = `#{compiler} --version 2>&1`.strip

SYSTEM_TEST_HOST = ENV.fetch('SYSTEM_TEST_HOST', "localhost")

task :report_toolchain do
  report_banner("Toolchain Configuration")
+1 −0
Original line number Diff line number Diff line
@@ -35,6 +35,7 @@
:defines:
  :commmon: &common_defines
    - TEST
    - SYSTEM_TEST_HOST=\"<%= ENV.fetch('SYSTEM_TEST_HOST', 'localhost') %>\"
  :test:
    - *common_defines
  :test_preprocess:
+9 −9
Original line number Diff line number Diff line
@@ -77,7 +77,7 @@ KineticStatus KineticClient_NoOp(KineticSession const * const session);
 *                      specify the data to be stored.
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 * 
 * @return              Returns the resulting KineticStatus.
 */
@@ -91,7 +91,7 @@ KineticStatus KineticClient_Put(KineticSession const * const session,
 * @param session       The connected KineticSession to use for the operation.
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 *                      
 * @return              Returns the resulting KineticStatus.
 */
@@ -106,7 +106,7 @@ KineticStatus KineticClient_Flush(KineticSession const * const session,
 *                      be populated unless 'metadataOnly' is set to 'true'.
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 *
 * @return              Returns the resulting KineticStatus.
 */
@@ -126,7 +126,7 @@ KineticStatus KineticClient_Get(KineticSession const * const session,
 *                      
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 *
 * @return              Returns the resulting KineticStatus.
 */
@@ -146,7 +146,7 @@ KineticStatus KineticClient_GetPrevious(KineticSession const * const session,
 *                      
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 *
 * @return              Returns the resulting KineticStatus.
 */
@@ -162,7 +162,7 @@ KineticStatus KineticClient_GetNext(KineticSession const * const session,
 *                      not used for this operation.
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 *
 * @return              Returns the resulting KineticStatus.
 */
@@ -179,7 +179,7 @@ KineticStatus KineticClient_Delete(KineticSession const * const session,
 * @param keys          ByteBufferArray to store the retrieved keys
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 *
 *
 * @return              Returns 0 upon success, -1 or the Kinetic status code
@@ -200,7 +200,7 @@ KineticStatus KineticClient_GetKeyRange(KineticSession const * const session,
 *                      the requested data, if successful.
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 *
 * @return              Returns 0 upon success, -1 or the Kinetic status code
 *                      upon failure
@@ -220,7 +220,7 @@ KineticStatus KineticClient_GetLog(KineticSession const * const session,
 *                      this structure.
 * @param closure       Optional closure. If specified, operation will be
 *                      executed in asynchronous mode, and closure callback
 *                      will be called upon completion.
 *                      will be called upon completion in another thread.
 *
 * @return              Returns 0 upon success, -1 or the Kinetic status code
 *                      upon failure. Note that P2P operations can be nested. This
+22 −21
Original line number Diff line number Diff line
@@ -560,27 +560,28 @@ void KineticOperation_BuildP2POperation(KineticOperation* const operation,
        KineticProto_Command_P2POperation_Operation * p2p_op_op = calloc(1, sizeof(KineticProto_Command_P2POperation_Operation));
        assert(p2p_op_op != NULL);

        (*p2p_op_op) = (KineticProto_Command_P2POperation_Operation){
            .has_key = true,
            .key.data = p2pOp->operations[i].key.array.data,
            .key.len = p2pOp->operations[i].key.bytesUsed,
        KineticProto_command_p2_poperation_operation__init(p2p_op_op);

            .has_newKey = !ByteBuffer_IsNull(p2pOp->operations[i].newKey),
            .newKey.data = p2pOp->operations[i].newKey.array.data,
            .newKey.len = p2pOp->operations[i].newKey.bytesUsed,
        p2p_op_op->has_key = true;
        p2p_op_op->key.data = p2pOp->operations[i].key.array.data;
        p2p_op_op->key.len = p2pOp->operations[i].key.bytesUsed;

            .has_version = !ByteBuffer_IsNull(p2pOp->operations[i].version),
            .version.data = p2pOp->operations[i].version.array.data,
            .version.len = p2pOp->operations[i].version.bytesUsed,
        p2p_op_op->has_newKey = !ByteBuffer_IsNull(p2pOp->operations[i].newKey);
        p2p_op_op->newKey.data = p2pOp->operations[i].newKey.array.data;
        p2p_op_op->newKey.len = p2pOp->operations[i].newKey.bytesUsed;

        p2p_op_op->has_version = !ByteBuffer_IsNull(p2pOp->operations[i].version);
        p2p_op_op->version.data = p2pOp->operations[i].version.array.data;
        p2p_op_op->version.len = p2pOp->operations[i].version.bytesUsed;

        // force if no version was specified
            .has_force = ByteBuffer_IsNull(p2pOp->operations[i].version),
            .force = ByteBuffer_IsNull(p2pOp->operations[i].version),
        p2p_op_op->has_force = ByteBuffer_IsNull(p2pOp->operations[i].version);
        p2p_op_op->force = ByteBuffer_IsNull(p2pOp->operations[i].version);

        // no nesting for now
            .p2pop = NULL,
            .status = NULL,
        };
        p2p_op_op->p2pop = NULL;
        p2p_op_op->status = NULL;

        operation->request->command->body->p2pOperation->operation[i] = p2p_op_op;
    }

Loading