Package com.oltpbenchmark.benchmarks.auctionmark.util

Examples of com.oltpbenchmark.benchmarks.auctionmark.util.UserId.encode()


       
        // USER_WATCH records
        rand = profile.rng.number(0, 100);
        boolean get_watched_items = (rand <= AuctionMarkConstants.PROB_GETUSERINFO_INCLUDE_WATCHED_ITEMS);
       
        List<Object[]>[] results = proc.run(conn, benchmarkTimes, userId.encode(),
                                                                  get_feedback,
                                                                  get_comments,
                                                                  get_seller_items,
                                                                  get_buyer_items,
                                                                  get_watched_items);
View Full Code Here


     
        // USER
        vt = results[idx++];
        assert(vt != null);
        assert(vt.size() > 0) :
            "Failed to find user information for " + userId + " / " + userId.encode();
         
        // USER_FEEDBACK
        if (get_feedback) {
            vt = results[idx];
            assert(vt != null);
View Full Code Here

            maxBid = profile.rng.fixedPoint(2, bid, (bid * (1 + (AuctionMarkConstants.ITEM_BID_PERCENT_STEP / 2))));
        }

        Object results[] = proc.run(conn, benchmarkTimes, itemInfo.itemId.encode(),
                                                          sellerId.encode(),
                                                          buyerId.encode(),
                                                          maxBid,
                                                          itemInfo.endDate);
        conn.commit();
       
        ItemId itemId = this.processItemRecord(results);
View Full Code Here

                                              AuctionMarkConstants.ITEM_COMMENT_LENGTH_MAX);
       
        Object results[] = proc.run(conn, benchmarkTimes,
                                          itemInfo.itemId.encode(),
                                          sellerId.encode(),
                                          buyerId.encode(),
                                          question);
        conn.commit();
        assert(results != null);
       
        profile.pending_commentResponses.add(new ItemCommentResponse(SQLUtil.getLong(results[0]),
View Full Code Here

        assert(cr != null);
       
        long commentId = cr.commentId.longValue();;
        ItemId itemId = new ItemId(cr.itemId.longValue());
        UserId sellerId = itemId.getSellerId();
        assert(sellerId.encode() == cr.sellerId);
        String response = profile.rng.astring(AuctionMarkConstants.ITEM_COMMENT_LENGTH_MIN,
                                              AuctionMarkConstants.ITEM_COMMENT_LENGTH_MAX);

        proc.run(conn, benchmarkTimes, itemId.encode(),
                                       sellerId.encode(),
View Full Code Here

        assert(sellerId.encode() == cr.sellerId);
        String response = profile.rng.astring(AuctionMarkConstants.ITEM_COMMENT_LENGTH_MIN,
                                              AuctionMarkConstants.ITEM_COMMENT_LENGTH_MAX);

        proc.run(conn, benchmarkTimes, itemId.encode(),
                                       sellerId.encode(),
                                       commentId,
                                       response);
        conn.commit();
       
        return (true);
View Full Code Here

       
        long user_id;
        long from_id;
        if (profile.rng.nextBoolean()) {
            user_id = sellerId.encode();
            from_id = buyerId.encode();
        } else {
            user_id = buyerId.encode();
            from_id = sellerId.encode();
        }
       
View Full Code Here

        long from_id;
        if (profile.rng.nextBoolean()) {
            user_id = sellerId.encode();
            from_id = buyerId.encode();
        } else {
            user_id = buyerId.encode();
            from_id = sellerId.encode();
        }
       
        proc.run(conn, benchmarkTimes, user_id,
                                       itemInfo.itemId.encode(),
View Full Code Here

        long duration = profile.randomDuration.nextInt();

        Object results[] = null;
        try {
            long itemIdEncoded = itemId.encode();
            results = proc.run(conn, benchmarkTimes, itemIdEncoded, sellerId.encode(),
                                                     categoryId, name, description,
                                                     duration, initial_price, attributes,
                                                     gag_ids, gav_ids, images);
        } catch (DuplicateItemIdException ex) {
            profile.seller_item_cnt.set(sellerId, ex.getItemCount());
View Full Code Here

                itemInfo.status = ItemStatus.CLOSED;
            }
        }
       
        Object results[] = proc.run(conn, benchmarkTimes, encodedItemId,
                                                          sellerId.encode(),
                                                          ip_id,
                                                          buyer_credit);
        conn.commit();
       
        ItemId itemId = this.processItemRecord(results);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.