Skip to content

Commit

Permalink
Add support to LOCAL_ONE consistency level
Browse files Browse the repository at this point in the history
  • Loading branch information
pauloricardomg committed Jan 31, 2014
1 parent ba20ca9 commit 504b60f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Modify retryDownedHosts() to only delete hosts not in the ring if autoDiscoverHo
Fix all hosts down check (@jancona)
don't use an iterator just to get item 0 of a List (@mebigfatguy)
Upgrade Cassandra dependencies to 1.2.11 (@pauloricardomg)
Add support to LOCAL_ONE consistency level (@pauloricardomg)

1.1-4
=====
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,13 @@ public static ConsistencyLevel consistencyLevel(HConsistencyLevel c) {
return ConsistencyLevel.EACH_QUORUM;
case LOCAL_QUORUM:
return ConsistencyLevel.LOCAL_QUORUM;
case LOCAL_ONE:
return ConsistencyLevel.LOCAL_ONE;
default:
throw new RuntimeException("Unregornized consistency level " + c);
}
}

/**
* Converts a list of ColumnOrSuperColumn to Column
* @param columns
Expand All @@ -50,5 +52,5 @@ public static List<Column> getColumnList(List<ColumnOrSuperColumn> columns) {
}
return list;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
* @author zznate
*/
public enum HConsistencyLevel {
ONE, TWO, THREE, QUORUM, ALL, ANY, EACH_QUORUM, LOCAL_QUORUM;
ONE, TWO, THREE, QUORUM, ALL, ANY, EACH_QUORUM, LOCAL_QUORUM, LOCAL_ONE;
}

0 comments on commit 504b60f

Please sign in to comment.