protected void rollbackCount(int fId) { ((StatisticalAssignmentPolicy)am.getPolicy()).updateStats(fId, -batchSize); }
protected Session getSession(int fId, boolean nextReplica, TransactionMode mode) { Session session = null; if (fastLoad) { List<ForestHost> replicas = am.getReplicas(forestIds[fId]);
switch (kind) { case BUCKET: initBucketPolicy(forests.toArray(new String[forests.size()]), updatableForests); break; case LEGACY: initLegacyPolicy(updatableForests); break; case SEGMENT: initSegmentPolicy(updatableForests); break; case RANGE: { .getFragmentCount(); initRangePolicy(countAry, batchSize); .getFragmentCount(); initStatisticalPolicy(countAry, batchSize); .getFragmentCount(); initQueryPolicy(countAry, batchSize);
if(!countBased) { fId = am.getPlacementForestIndex(key); sfId = fId; } else { if (sfId == -1) { sfId = am.getPlacementForestIndex(key);
super(conf, null); effectiveVersion = am.getEffectiveVersion(); isTxnCompatible = effectiveVersion == 0; forestIds = am.getMasterIds().clone(); srcMapSize = forestIds.length; curReplica = new int[srcMapSize]; && (am.getPolicy().getPolicyKind() == AssignmentPolicy.Kind.STATISTICAL || am.getPolicy().getPolicyKind() == AssignmentPolicy.Kind.RANGE || am.getPolicy().getPolicyKind() == AssignmentPolicy.Kind.QUERY)) { countBased = true; forestContents = new Content[1][batchSize];
if (!countBased) { fId = am.getPlacementForestIndex(key); sfId = fId; } else { if (sfId == -1) { sfId = am.getPlacementForestIndex(key);
if(!countBased) { fId = am.getPlacementForestIndex(key); sfId = fId; } else { if (sfId == -1) { sfId = am.getPlacementForestIndex(key);
if(!countBased) { fId = am.getPlacementForestIndex(key); sfId = fId; } else { if (sfId == -1) { sfId = am.getPlacementForestIndex(key);