Add comments about new keyspace name configuration properties, plus a test fix.
Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/f96f2889 Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/f96f2889 Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/f96f2889 Branch: refs/heads/two-dot-o-dev Commit: f96f28894e7b71d1205b95fe796650965576ef3e Parents: 8aff671 Author: Dave Johnson <dmjohn...@apigee.com> Authored: Mon Apr 20 10:47:57 2015 -0400 Committer: Dave Johnson <dmjohn...@apigee.com> Committed: Mon Apr 20 10:47:57 2015 -0400 ---------------------------------------------------------------------- .../main/resources/usergrid-default.properties | 27 ++++++++++++-------- .../rest/management/ManagementResourceIT.java | 7 +++-- 2 files changed, 21 insertions(+), 13 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/f96f2889/stack/config/src/main/resources/usergrid-default.properties ---------------------------------------------------------------------- diff --git a/stack/config/src/main/resources/usergrid-default.properties b/stack/config/src/main/resources/usergrid-default.properties index fe7a945..b895310 100644 --- a/stack/config/src/main/resources/usergrid-default.properties +++ b/stack/config/src/main/resources/usergrid-default.properties @@ -31,13 +31,16 @@ # URL for local testing Cassandra cluster cassandra.url=localhost:9160 -#The number of thrift connections to open per cassandra node. +# The number of thrift connections to open per cassandra node. cassandra.connections=50 - # Name of Cassandra cluster cassandra.cluster=Test Cluster +# Keyspace names to be used (see also the locks keyspace below) +cassandra.system.keyspace=Usergrid +cassandra.application.keyspace=Usergrid_Applications + cassandra.keyspace.strategy=org.apache.cassandra.locator.SimpleStrategy #cassandra.keyspace.strategy=org.apache.cassandra.locator.NetworkTopologyStrategy @@ -49,18 +52,19 @@ cassandra.keyspace.replication=1 cassandra.username= cassandra.password= -#Read consistency level for the cassandra cluster +# Read consistency level for the cassandra cluster cassandra.readcl=QUORUM -#Write consistency level for the cassandra cluster +# Write consistency level for the cassandra cluster cassandra.writecl=QUORUM -#The maximum number of pending mutations allowed in ram before it is flushed to cassandra +# The maximum number of pending mutations allowed in ram before it is flushed to cassandra cassandra.mutation.flushsize=2000 -#Keyspace to use for locking -#Note that if this is deployed in a production cluster, the RF on the keyspace MUST be updated to use an odd number for it's replication Factor. -#Even numbers for RF can potentially case the locks to fail, via "split brain" when read at QUORUM on lock verification +# Keyspace to use for locking - Used by Hector lock manager: +# Note that if this is deployed in a production cluster, the RF on the keyspace MUST +# be updated to use an odd number for it's replication Factor. Even numbers for RF can +# potentially case the locks to fail, via "split brain" when read at QUORUM on lock verification cassandra.lock.keyspace=Locks # false to disable test features @@ -111,9 +115,10 @@ usergrid.sysadmin.login.allowed=false usergrid.sysadmin.approve.users=false usergrid.sysadmin.approve.organizations=false -# Base URL of central Usergrid SSO server -# Setting this will enable external token validation. -# See also: https://issues.apache.org/jira/browse/USERGRID-567 +# Base URL of central Usergrid SSO server: +# Setting this will enable External Token Validation for Admin Users and will configure +# this Usergrid instance delegate all Admin User authentication to the central Usegrid SSO +# server. See also: https://issues.apache.org/jira/browse/USERGRID-567 usergrid.central.url= # Where to store temporary files http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/f96f2889/stack/rest/src/test/java/org/apache/usergrid/rest/management/ManagementResourceIT.java ---------------------------------------------------------------------- diff --git a/stack/rest/src/test/java/org/apache/usergrid/rest/management/ManagementResourceIT.java b/stack/rest/src/test/java/org/apache/usergrid/rest/management/ManagementResourceIT.java index 2cec9ac..651fcdf 100644 --- a/stack/rest/src/test/java/org/apache/usergrid/rest/management/ManagementResourceIT.java +++ b/stack/rest/src/test/java/org/apache/usergrid/rest/management/ManagementResourceIT.java @@ -695,8 +695,11 @@ public class ManagementResourceIT extends AbstractRestIT { .queryParam( "ttl", "1000" ) .get( JsonNode.class ); fail("Validation should have failed"); - } catch ( Exception actual ) { - logger.debug( "error", actual ); + } catch ( UniformInterfaceException actual ) { + assertEquals( 400, actual.getResponse().getStatus() ); + String errorMsg = actual.getResponse().getEntity( JsonNode.class ).get( "error_description" ).toString(); + logger.error( "ERROR: " + errorMsg ); + assertTrue( errorMsg.contains( "Admin Users must login via" ) ); }