You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by sn...@apache.org on 2014/01/20 19:20:23 UTC
[1/3] Minor formatting fixes plus license headers.
Updated Branches:
refs/heads/two-dot-o d8459deec -> 8773a1833
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Entity.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Entity.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Entity.java
index 265c1ae..7a0eb5d 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Entity.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Entity.java
@@ -1,10 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.entity;
import java.util.UUID;
-
import org.apache.usergrid.persistence.model.field.value.EntityObject;
-
import com.google.common.base.Preconditions;
@@ -27,7 +43,6 @@ public class Entity extends EntityObject {
private UUID version;
-
/**
* Create an entity with the given type and id. Should be used for all update operations to an existing entity
*/
@@ -47,7 +62,6 @@ public class Entity extends EntityObject {
}
-
/**
* Do not use! This is only for serialization.
*/
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Id.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Id.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Id.java
index 3a9d49b..d456325 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Id.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/Id.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.entity;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/SimpleId.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/SimpleId.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/SimpleId.java
index 08ae920..e894891 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/SimpleId.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/entity/SimpleId.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.entity;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ArrayField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ArrayField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ArrayField.java
index cb5f45d..1e45884 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ArrayField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ArrayField.java
@@ -1,27 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field;
+/**
+ * A marker to signal array handling. Just delegates to list field for easier handling internally
+ */
+public class ArrayField extends ListField {
-import java.util.ArrayList;
-import java.util.List;
-
-
-/** A marker to signal array handling. Just delegates to list field for easier handling internally */
-public class ArrayField extends ListField
-{
-
- /** Contructor that intializes with an empty set for adding to later */
- public ArrayField( String name )
- {
- super(name);
+ /**
+ * Contructor that intializes with an empty set for adding to later
+ */
+ public ArrayField( String name ) {
+ super( name );
}
- public ArrayField(){
+ public ArrayField() {
super();
}
- /** Add the value to the list */
- public void add( Field field )
- {
+ /**
+ * Add the value to the list
+ */
+ public void add( Field field ) {
value.add( field );
}
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/BooleanField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/BooleanField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/BooleanField.java
index 63097e0..fed011d 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/BooleanField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/BooleanField.java
@@ -18,9 +18,7 @@
package org.apache.usergrid.persistence.model.field;
/**
- *
* @author: tnine
- *
*/
public class BooleanField extends AbstractField<Boolean> {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ByteBufferField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ByteBufferField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ByteBufferField.java
index 2dbc193..29dcb6b 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ByteBufferField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ByteBufferField.java
@@ -1,28 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field;
-
import java.nio.ByteBuffer;
+/**
+ * A field for storing byte buffers
+ */
+public class ByteBufferField extends AbstractField<ByteBuffer> {
-/** A field for storing byte buffers */
-public class ByteBufferField extends AbstractField<ByteBuffer>
-{
-
-
- /** Creates an immutable copy of the byte buffer */
- public ByteBufferField( String name, ByteBuffer value )
- {
+ /**
+ * Creates an immutable copy of the byte buffer
+ */
+ public ByteBufferField( String name, ByteBuffer value ) {
//always return a duplicate so we don't mess with the markers
super( name, value.duplicate() );
}
public ByteBufferField() {
- }
+ }
@Override
- public ByteBuffer getValue()
- {
+ public ByteBuffer getValue() {
//always return a duplicate so we don't mess with the markers
return value.duplicate();
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/DoubleField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/DoubleField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/DoubleField.java
index 07f847c..2f358bd 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/DoubleField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/DoubleField.java
@@ -18,9 +18,7 @@
package org.apache.usergrid.persistence.model.field;
/**
- *
* @author: tnine
- *
*/
public class DoubleField extends AbstractField<Double> {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/EntityObjectField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/EntityObjectField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/EntityObjectField.java
index d44ba2f..7739291 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/EntityObjectField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/EntityObjectField.java
@@ -1,20 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field;
-
import org.apache.usergrid.persistence.model.field.value.EntityObject;
+/**
+ * An object field
+ */
+public class EntityObjectField extends AbstractField<EntityObject> {
-/** An object field */
-public class EntityObjectField extends AbstractField<EntityObject>
-{
-
-
- public EntityObjectField( String name, EntityObject value )
- {
+ public EntityObjectField( String name, EntityObject value ) {
super( name, value );
}
public EntityObjectField() {
- }
+ }
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/Field.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/Field.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/Field.java
index 4f5a917..460ca9e 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/Field.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/Field.java
@@ -1,12 +1,28 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field;
-
import java.io.Serializable;
-
/**
- * Interface for fields. All fields must implement this method The T is the type of field (in the java runtime) The V
- * is the value of the field
+ * Interface for fields. All fields must implement this method The T is the type of field
+ * (in the java runtime) The V is the value of the field
* @param <T>
*/
public interface Field<T> extends Serializable {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/IntegerField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/IntegerField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/IntegerField.java
index 6a311e6..6412b35 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/IntegerField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/IntegerField.java
@@ -18,9 +18,7 @@
package org.apache.usergrid.persistence.model.field;
/**
- *
* @author: tnine
- *
*/
public class IntegerField extends AbstractField<Integer> {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ListField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ListField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ListField.java
index 0795201..cb0e297 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ListField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/ListField.java
@@ -1,28 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field;
-
import java.util.ArrayList;
import java.util.List;
+/**
+ * An object field that represents a list of objects. This can also be used to represent arrays
+ */
+public class ListField extends AbstractField<List<Field>> {
-/** An object field that represents a list of objects. This can also be used to represent arrays */
-public class ListField extends AbstractField<List<Field>>
-{
-
- /** Contructor that intializes with an empty set for adding to later */
- public ListField( String name )
- {
+ /**
+ * Contructor that intializes with an empty set for adding to later
+ */
+ public ListField( String name ) {
super( name, new ArrayList<Field>() );
}
- public ListField(){
+ public ListField() {
super();
}
-
- /** Add the value to the list */
- public void add( Field field )
- {
+ /**
+ * Add the value to the list
+ */
+ public void add( Field field ) {
value.add( field );
}
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/LocationField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/LocationField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/LocationField.java
index 76d1094..29e3169 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/LocationField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/LocationField.java
@@ -1,20 +1,38 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field;
-
import org.apache.usergrid.persistence.model.field.value.Location;
+/**
+ * Basic field for storing location data
+ */
+public class LocationField extends AbstractField<Location> {
-/** Basic field for storing location data */
-public class LocationField extends AbstractField<Location>
-{
-
- /** Create a location field with the given point */
- public LocationField( String name, Location value )
- {
+ /**
+ * Create a location field with the given point
+ */
+ public LocationField( String name, Location value ) {
super( name, value );
}
public LocationField() {
- }
+ }
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/SetField.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/SetField.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/SetField.java
index f28b5ec..329289c 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/SetField.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/SetField.java
@@ -1,28 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field;
-
import java.util.LinkedHashSet;
import java.util.Set;
+/**
+ * An object field that represents a set of objects
+ */
+public class SetField extends AbstractField<Set<Field>> {
-/** An object field that represents a set of objects */
-public class SetField extends AbstractField<Set<Field>>
-{
-
-
- /** Contructor that intializes with an empty set for adding to later */
- public SetField( String name )
- {
+ /**
+ * Contructor that intializes with an empty set for adding to later
+ */
+ public SetField( String name ) {
super( name, new LinkedHashSet<Field>() );
}
public SetField() {
- }
+ }
- /** Add an entry to the set */
- public void addEntry( Field field )
- {
+ /**
+ * Add an entry to the set
+ */
+ public void addEntry( Field field ) {
value.add( field );
}
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/EntityObject.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/EntityObject.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/EntityObject.java
index fb69afb..e898392 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/EntityObject.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/EntityObject.java
@@ -1,6 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field.value;
-
import java.io.Serializable;
import java.util.Collection;
import java.util.HashMap;
@@ -8,33 +25,34 @@ import java.util.Map;
import org.apache.usergrid.persistence.model.field.Field;
+/**
+ * Simple wrapper for holding nested objects
+ */
+public class EntityObject implements Serializable {
-/** Simple wrapper for holding nested objects */
-public class EntityObject implements Serializable
-{
-
-
- /** Fields the users can set */
- private Map<String, Field> fields = new HashMap<String, Field>();
+ /**
+ * Fields the users can set
+ */
+ private final Map<String, Field> fields = new HashMap<String, Field>();
-
- /** Add the field, return the old one if it existed */
- public <T extends java.lang.Object> Field<T> setField( Field<T> value )
- {
+ /**
+ * Add the field, return the old one if it existed
+ */
+ public <T extends java.lang.Object> Field<T> setField( Field<T> value ) {
return fields.put( value.getName(), value );
}
-
- /** Get the field by name the user has set into the entity */
- public <T extends java.lang.Object> Field<T> getField( String name )
- {
+ /**
+ * Get the field by name the user has set into the entity
+ */
+ public <T extends java.lang.Object> Field<T> getField( String name ) {
return fields.get( name );
}
-
- /** Get all fields in the entity */
- public Collection<Field> getFields()
- {
+ /**
+ * Get all fields in the entity
+ */
+ public Collection<Field> getFields() {
return fields.values();
}
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/Location.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/Location.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/Location.java
index 083f211..224c750 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/Location.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/field/value/Location.java
@@ -1,32 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.field.value;
-
import java.io.Serializable;
-
-/** Geographic point. Should be used when we want to store geo information */
-public class Location implements Serializable
-{
+/**
+ * Geographic point. Should be used when we want to store geo information
+ */
+public class Location implements Serializable {
private final double latitude;
private final double longtitude;
-
- public Location( double latitude, double longtitude )
- {
+ public Location( double latitude, double longtitude ) {
this.latitude = latitude;
this.longtitude = longtitude;
}
-
- public double getLatitude()
- {
+ public double getLatitude() {
return latitude;
}
-
- public double getLongtitude()
- {
+ public double getLongtitude() {
return longtitude;
}
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/util/Verify.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/util/Verify.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/util/Verify.java
index c7dd642..c6616ed 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/util/Verify.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/util/Verify.java
@@ -1,6 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.util;
-
/**
* Class to help with input verification
*/
@@ -15,7 +32,6 @@ public class Verify {
if(value != null){
throw new IllegalArgumentException(message );
}
-
}
@@ -33,5 +49,4 @@ public class Verify {
throw new IllegalArgumentException( message );
}
}
-
}
[2/3] git commit: Minor formatting fixes plus license headers.
Posted by sn...@apache.org.
Minor formatting fixes plus license headers.
Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/1aba6206
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/1aba6206
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/1aba6206
Branch: refs/heads/two-dot-o
Commit: 1aba62062b3d839d72ede9f7047608caaf224c7f
Parents: d8459de
Author: Dave Johnson <dm...@apigee.com>
Authored: Mon Jan 20 10:56:16 2014 -0500
Committer: Dave Johnson <dm...@apigee.com>
Committed: Mon Jan 20 10:56:16 2014 -0500
----------------------------------------------------------------------
.../DynamicCompositeFieldSerializer.java | 5 +-
.../IdColDynamicCompositeSerializer.java | 5 +-
.../persistence/collection/CollectionScope.java | 18 ++++++
.../collection/EntityCollectionManager.java | 18 ++++++
.../EntityCollectionManagerFactory.java | 52 +++++++++++++-----
.../collection/EntityCollectionManagerSync.java | 20 ++++++-
.../collection/OrganizationScope.java | 18 ++++++
.../astyanax/AstyanaxKeyspaceProvider.java | 18 ++++++
.../collection/astyanax/CassandraFig.java | 18 ++++++
.../astyanax/CompositeFieldSerializer.java | 18 ++++++
.../astyanax/IdRowCompositeSerializer.java | 18 ++++++
.../astyanax/MultiTennantColumnFamily.java | 21 ++++++-
.../MultiTennantColumnFamilyDefinition.java | 18 ++++++
.../collection/astyanax/ScopedRowKey.java | 22 +++++++-
.../collection/guice/PropertyUtils.java | 18 ++++++
.../collection/impl/CollectionScopeImpl.java | 18 ++++++
.../impl/EntityCollectionManagerImpl.java | 18 ++++++
.../impl/EntityCollectionManagerSyncImpl.java | 18 ++++++
.../collection/migration/Migration.java | 18 ++++++
.../migration/MigrationException.java | 18 ++++++
.../collection/migration/MigrationManager.java | 18 ++++++
.../mvcc/MvccEntitySerializationStrategy.java | 18 ++++++
.../mvcc/MvccLogEntrySerializationStrategy.java | 18 ++++++
.../collection/mvcc/entity/MvccEntity.java | 18 ++++++
.../collection/mvcc/entity/MvccLogEntry.java | 18 ++++++
.../collection/mvcc/entity/Stage.java | 18 ++++++
.../collection/mvcc/entity/ValidationUtils.java | 18 ++++++
.../mvcc/entity/impl/MvccEntityImpl.java | 21 ++++++-
.../mvcc/entity/impl/MvccLogEntryImpl.java | 18 ++++++
.../mvcc/event/PostProcessObserver.java | 21 ++++++-
.../mvcc/stage/CollectionIoEvent.java | 19 ++++++-
.../mvcc/stage/delete/DeleteCommit.java | 46 +++++++++++-----
.../mvcc/stage/delete/DeleteStart.java | 31 +++++++++--
.../collection/mvcc/stage/load/Load.java | 30 ++++++++--
.../mvcc/stage/write/UniqueValueImpl.java | 2 +-
.../collection/rx/CassandraThreadScheduler.java | 44 ++++++++++-----
.../persistence/collection/rx/Concurrent.java | 42 ++++++++++----
.../persistence/collection/rx/RxFig.java | 18 ++++++
.../model/builder/EntitySerializer.java | 19 ++++++-
.../model/builder/EntitySerializerFactory.java | 20 ++++++-
.../persistence/model/entity/Entity.java | 22 ++++++--
.../usergrid/persistence/model/entity/Id.java | 18 ++++++
.../persistence/model/entity/SimpleId.java | 18 ++++++
.../persistence/model/field/ArrayField.java | 48 ++++++++++------
.../persistence/model/field/BooleanField.java | 2 -
.../model/field/ByteBufferField.java | 40 ++++++++++----
.../persistence/model/field/DoubleField.java | 2 -
.../model/field/EntityObjectField.java | 33 ++++++++---
.../usergrid/persistence/model/field/Field.java | 24 ++++++--
.../persistence/model/field/IntegerField.java | 2 -
.../persistence/model/field/ListField.java | 44 ++++++++++-----
.../persistence/model/field/LocationField.java | 36 +++++++++---
.../persistence/model/field/SetField.java | 44 ++++++++++-----
.../model/field/value/EntityObject.java | 58 +++++++++++++-------
.../persistence/model/field/value/Location.java | 39 ++++++++-----
.../usergrid/persistence/model/util/Verify.java | 21 ++++++-
56 files changed, 1080 insertions(+), 205 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/DynamicCompositeFieldSerializer.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/DynamicCompositeFieldSerializer.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/DynamicCompositeFieldSerializer.java
index 17a0fe2..1aae61e 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/DynamicCompositeFieldSerializer.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/DynamicCompositeFieldSerializer.java
@@ -24,8 +24,9 @@ import com.netflix.astyanax.model.DynamicComposite;
/**
- * This interface is for re-using multiple components in a composite. Implementing this allows many different types to
- * be serialized together in a single composite
+ * This interface is for re-using multiple components in a composite.
+ * Implementing this allows many different types to be serialized
+ * together in a single composite
*
* @author tnine
*/
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/IdColDynamicCompositeSerializer.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/IdColDynamicCompositeSerializer.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/IdColDynamicCompositeSerializer.java
index cd7dd99..44da06b 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/IdColDynamicCompositeSerializer.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/astyanax/IdColDynamicCompositeSerializer.java
@@ -16,7 +16,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-
package org.apache.usergrid.persistence.astyanax;
@@ -42,7 +41,8 @@ public class IdColDynamicCompositeSerializer implements DynamicCompositeFieldSer
private static final StringSerializer STRING_SERIALIZER = StringSerializer.get();
private static final UUIDSerializer UUID_SERIALIZER = UUIDSerializer.get();
- private static final IdColDynamicCompositeSerializer INSTANCE = new IdColDynamicCompositeSerializer();
+ private static final IdColDynamicCompositeSerializer INSTANCE =
+ new IdColDynamicCompositeSerializer();
private IdColDynamicCompositeSerializer() {
@@ -50,7 +50,6 @@ public class IdColDynamicCompositeSerializer implements DynamicCompositeFieldSer
}
-
/**
* Get the singleton serializer
*/
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.java
index 4d6fbbf..be5924d 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java
index 9942fba..3322164 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerFactory.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerFactory.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerFactory.java
index 05e5093..59a5e09 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerFactory.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerFactory.java
@@ -1,35 +1,59 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection;
/**
- * A basic factory that creates a collection manager with the given context. Each instance of this factory should exist
- * for a Single OrganizationScope
+ * A basic factory that creates a collection manager with the given context.
+ * Each instance of this factory should exist for a Single OrganizationScope
*/
public interface EntityCollectionManagerFactory {
/**
- * Create a new EntityCollectionManager for the given context. The EntityCollectionManager can safely be used on the
- * current thread and will cache responses. The returned instance should not be shared among threads it will not be
- * guaranteed to be thread safe.
+ * Create a new EntityCollectionManager for the given context.
+ * The EntityCollectionManager can safely be used on the current thread
+ * and will cache responses. The returned instance should not be shared
+ * among threads it will not be guaranteed to be thread safe.
*
- * @param collectionScope The collectionScope collectionScope to use when creating the collectionScope manager
+ * @param collectionScope The collectionScope collectionScope to use
+ * when creating the collectionScope manager
*
* @return The collectionScope manager to perform operations within the provided context
*/
- public EntityCollectionManager createCollectionManager( CollectionScope collectionScope );
+ public EntityCollectionManager
+ createCollectionManager( CollectionScope collectionScope );
/**
- * Create a new EntityCollectionManagerSync for the given context. The EntityCollectionManager can safely be used on the
- * current thread and will cache responses. The returned instance should not be shared among threads it will not be
- * guaranteed to be thread safe. This implementation will be synchronous.
- * Try to use the async implementation if possible
- *
+ * Create a new EntityCollectionManagerSync for the given context.
+ * The EntityCollectionManager can safely be used on the current thread
+ * and will cache responses. The returned instance should not be shared
+ * among threads it will not be guaranteed to be thread safe.
+ * This implementation will be synchronous. Try to use the async
+ * implementation if possible
*
- * @param collectionScope The collectionScope collectionScope to use when creating the collectionScope manager
+ * @param collectionScope The collectionScope collectionScope to use when
+ * creating the collectionScope manager
*
* @return The collectionScope manager to perform operations within the provided context
*/
- public EntityCollectionManagerSync createCollectionManagerSync( CollectionScope collectionScope );
+ public EntityCollectionManagerSync
+ createCollectionManagerSync( CollectionScope collectionScope );
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerSync.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerSync.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerSync.java
index 32654c7..34181e9 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerSync.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManagerSync.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection;
@@ -6,10 +24,8 @@ import org.apache.usergrid.persistence.model.entity.Id;
/**
- *
* A synchronous implementation that will block until the call is returned.
* @author: tnine
- *
*/
public interface EntityCollectionManagerSync {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/OrganizationScope.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/OrganizationScope.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/OrganizationScope.java
index 34129cb..f168e7b 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/OrganizationScope.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/OrganizationScope.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/AstyanaxKeyspaceProvider.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/AstyanaxKeyspaceProvider.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/AstyanaxKeyspaceProvider.java
index 512f2fa..12ba2ca 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/AstyanaxKeyspaceProvider.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/AstyanaxKeyspaceProvider.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.astyanax;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CassandraFig.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CassandraFig.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CassandraFig.java
index 0728656..6ff9828 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CassandraFig.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CassandraFig.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.astyanax;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CompositeFieldSerializer.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CompositeFieldSerializer.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CompositeFieldSerializer.java
index 062645c..dc91b16 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CompositeFieldSerializer.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/CompositeFieldSerializer.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.astyanax;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/IdRowCompositeSerializer.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/IdRowCompositeSerializer.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/IdRowCompositeSerializer.java
index d3e9f34..8444adc 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/IdRowCompositeSerializer.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/IdRowCompositeSerializer.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.astyanax;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamily.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamily.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamily.java
index 73a354c..b69c7a2 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamily.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamily.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.astyanax;
@@ -12,7 +30,8 @@ import com.netflix.astyanax.model.ColumnFamily;
*
* @author tnine
*/
-public class MultiTennantColumnFamily<S extends OrganizationScope, K, V> extends ColumnFamily<ScopedRowKey<S, K>, V> {
+public class MultiTennantColumnFamily<S extends OrganizationScope, K, V>
+ extends ColumnFamily<ScopedRowKey<S, K>, V> {
public MultiTennantColumnFamily(
final String columnFamilyName,
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamilyDefinition.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamilyDefinition.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamilyDefinition.java
index 9adfb19..764ae36 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamilyDefinition.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/MultiTennantColumnFamilyDefinition.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.astyanax;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/ScopedRowKey.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/ScopedRowKey.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/ScopedRowKey.java
index dd47881..c2eaa90 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/ScopedRowKey.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/astyanax/ScopedRowKey.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.astyanax;
@@ -7,8 +25,8 @@ import com.google.common.base.Preconditions;
/**
- * A row key that is within a Scope. Every I/O operation should be using this class. No keys should be allowed that
- * aren't within a Scope
+ * A row key that is within a Scope. Every I/O operation should be using this class.
+ * No keys should be allowed that aren't within a Scope
*
* @author tnine
*/
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/PropertyUtils.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/PropertyUtils.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/PropertyUtils.java
index 54c3475..629813c 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/PropertyUtils.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/PropertyUtils.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.guice;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java
index 3776e12..38dcad1 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.impl;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java
index b5237b5..12bca5d 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.impl;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerSyncImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerSyncImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerSyncImpl.java
index ddd1e8d..c04e70b 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerSyncImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerSyncImpl.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.impl;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/Migration.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/Migration.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/Migration.java
index 9074386..8d83364 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/Migration.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/Migration.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.migration;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationException.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationException.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationException.java
index 3003940..a3487dc 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationException.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationException.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.migration;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationManager.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationManager.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationManager.java
index 94fa9ac..7cb4103 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationManager.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/migration/MigrationManager.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.migration;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccEntitySerializationStrategy.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccEntitySerializationStrategy.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccEntitySerializationStrategy.java
index 73ff5a8..c7fba3b 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccEntitySerializationStrategy.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccEntitySerializationStrategy.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccLogEntrySerializationStrategy.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccLogEntrySerializationStrategy.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccLogEntrySerializationStrategy.java
index b25c0dd..a7c9d64 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccLogEntrySerializationStrategy.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/MvccLogEntrySerializationStrategy.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccEntity.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccEntity.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccEntity.java
index 011a561..7419041 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccEntity.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccEntity.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.entity;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccLogEntry.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccLogEntry.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccLogEntry.java
index 0d32ecf..a285a78 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccLogEntry.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccLogEntry.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.entity;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/Stage.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/Stage.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/Stage.java
index 928afa0..007f013 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/Stage.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/Stage.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.entity;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/ValidationUtils.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/ValidationUtils.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/ValidationUtils.java
index 0d416ed..98fa14e 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/ValidationUtils.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/ValidationUtils.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.entity;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityImpl.java
index 6f29cac..39e525e 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityImpl.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.entity.impl;
@@ -26,7 +44,8 @@ public class MvccEntityImpl implements MvccEntity {
}
- public MvccEntityImpl( final Id entityId, final UUID version, final Optional<Entity> entity ) {
+ public MvccEntityImpl(
+ final Id entityId, final UUID version, final Optional<Entity> entity ) {
Preconditions.checkNotNull( entityId, "entity id is required" );
Preconditions.checkNotNull( version, "version id is required" );
Preconditions.checkNotNull( entity, "entity is required" );
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccLogEntryImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccLogEntryImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccLogEntryImpl.java
index 5065405..4b5552e 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccLogEntryImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccLogEntryImpl.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.entity.impl;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/event/PostProcessObserver.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/event/PostProcessObserver.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/event/PostProcessObserver.java
index 223a5d3..b06957d 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/event/PostProcessObserver.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/event/PostProcessObserver.java
@@ -1,14 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.event;
-
import org.apache.usergrid.persistence.collection.CollectionScope;
import org.apache.usergrid.persistence.collection.mvcc.entity.MvccEntity;
/**
- *
* @author: tnine
- *
*/
public interface PostProcessObserver {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java
index e74e41d..1ad270f 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java
@@ -1,6 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.stage;
-
import org.apache.usergrid.persistence.collection.CollectionScope;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteCommit.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteCommit.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteCommit.java
index ef456fa..2cf393b 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteCommit.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteCommit.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.stage.delete;
@@ -27,28 +45,28 @@ import rx.util.functions.Func1;
/**
- * This phase should invoke any finalization, and mark the entity as committed in the data store before returning
+ * This phase should invoke any finalization, and mark the entity
+ * as committed in the data store before returning
*/
@Singleton
public class DeleteCommit implements Func1<CollectionIoEvent<MvccEntity>, Void> {
-
private static final Logger LOG = LoggerFactory.getLogger( DeleteCommit.class );
- private final MvccLogEntrySerializationStrategy logEntrySerializationStrategy;
- private final MvccEntitySerializationStrategy entitySerializationStrategy;
-
+ private final MvccLogEntrySerializationStrategy logStrat;
+ private final MvccEntitySerializationStrategy entityStrat;
@Inject
- public DeleteCommit( final MvccLogEntrySerializationStrategy logEntrySerializationStrategy,
- final MvccEntitySerializationStrategy entitySerializationStrategy ) {
-
- Preconditions.checkNotNull( logEntrySerializationStrategy, "logEntrySerializationStrategy is required" );
- Preconditions.checkNotNull( entitySerializationStrategy, "entitySerializationStrategy is required" );
+ public DeleteCommit( final MvccLogEntrySerializationStrategy logStrat,
+ final MvccEntitySerializationStrategy entityStrat ) {
+ Preconditions.checkNotNull(
+ logStrat, "logEntrySerializationStrategy is required" );
+ Preconditions.checkNotNull(
+ entityStrat, "entitySerializationStrategy is required" );
- this.logEntrySerializationStrategy = logEntrySerializationStrategy;
- this.entitySerializationStrategy = entitySerializationStrategy;
+ this.logStrat = logStrat;
+ this.entityStrat = entityStrat;
}
@@ -69,10 +87,10 @@ public class DeleteCommit implements Func1<CollectionIoEvent<MvccEntity>, Void>
final MvccLogEntry startEntry = new MvccLogEntryImpl( entityId, version,
org.apache.usergrid.persistence.collection.mvcc.entity.Stage.COMMITTED );
- MutationBatch logMutation = logEntrySerializationStrategy.write( collectionScope, startEntry );
+ MutationBatch logMutation = logStrat.write( collectionScope, startEntry );
//insert a "cleared" value into the versions. Post processing should actually delete
- MutationBatch entityMutation = entitySerializationStrategy.clear( collectionScope, entityId, version );
+ MutationBatch entityMutation = entityStrat.clear( collectionScope, entityId, version );
//merge the 2 into 1 mutation
logMutation.mergeShallow( entityMutation );
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteStart.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteStart.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteStart.java
index 7bab25b..b7d6268 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteStart.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/DeleteStart.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.stage.delete;
@@ -31,8 +49,9 @@ import rx.util.functions.Func1;
/**
- * This is the first stage and should be invoked immediately when a write is started. It should persist the start of a
- * new write in the data store for a checkpoint and recovery
+ * This is the first stage and should be invoked immediately when a write is started.
+ * It should persist the start of a new write in the data store for
+ * a checkpoint and recovery
*/
@Singleton
public class DeleteStart implements Func1<CollectionIoEvent<Id>, CollectionIoEvent<MvccEntity>> {
@@ -48,7 +67,10 @@ public class DeleteStart implements Func1<CollectionIoEvent<Id>, CollectionIoEve
* Create a new stage with the current context
*/
@Inject
- public DeleteStart( final MvccLogEntrySerializationStrategy logStrategy, final UUIDService uuidService ) {
+ public DeleteStart(
+ final MvccLogEntrySerializationStrategy logStrategy,
+ final UUIDService uuidService ) {
+
Preconditions.checkNotNull( logStrategy, "logStrategy is required" );
Preconditions.checkNotNull( uuidService, "uuidService is required" );
@@ -84,7 +106,8 @@ public class DeleteStart implements Func1<CollectionIoEvent<Id>, CollectionIoEve
//create the mvcc entity for the next stage
- final MvccEntityImpl nextStage = new MvccEntityImpl( entityId, version, Optional.<Entity>absent() );
+ final MvccEntityImpl nextStage = new MvccEntityImpl(
+ entityId, version, Optional.<Entity>absent() );
return new CollectionIoEvent<MvccEntity>( collectionScope, nextStage );
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/load/Load.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/load/Load.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/load/Load.java
index 803983d..6f61d3e 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/load/Load.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/load/Load.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.mvcc.stage.load;
@@ -38,8 +56,10 @@ public class Load implements Func1<CollectionIoEvent<Id>, Entity> {
@Inject
- public Load( final UUIDService uuidService, final MvccEntitySerializationStrategy entitySerializationStrategy ) {
- Preconditions.checkNotNull( entitySerializationStrategy, "entitySerializationStrategy is required" );
+ public Load( final UUIDService uuidService,
+ final MvccEntitySerializationStrategy entitySerializationStrategy ) {
+ Preconditions.checkNotNull( entitySerializationStrategy,
+ "entitySerializationStrategy is required" );
Preconditions.checkNotNull( uuidService, "uuidService is required" );
@@ -60,7 +80,8 @@ public class Load implements Func1<CollectionIoEvent<Id>, Entity> {
//generate a version that represents now
final UUID versionMax = uuidService.newTimeUUID();
- List<MvccEntity> results = entitySerializationStrategy.load( collectionScope, entityId, versionMax, 1 );
+ List<MvccEntity> results = entitySerializationStrategy.load(
+ collectionScope, entityId, versionMax, 1 );
//nothing to do, we didn't get a result back
if ( results.size() != 1 ) {
@@ -69,7 +90,8 @@ public class Load implements Func1<CollectionIoEvent<Id>, Entity> {
final Optional<Entity> targetVersion = results.get( 0 ).getEntity();
- //this entity has been marked as cleared. The version exists, but does not have entity data
+ //this entity has been marked as cleared.
+ //The version exists, but does not have entity data
if ( !targetVersion.isPresent() ) {
//TODO, a lazy async repair/cleanup here?
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/UniqueValueImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/UniqueValueImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/UniqueValueImpl.java
index 686eb1f..76ac439 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/UniqueValueImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/UniqueValueImpl.java
@@ -30,7 +30,7 @@ public class UniqueValueImpl implements UniqueValue {
private final CollectionScope collectionScope;
private final Field field;
private final Id entityId;
- private UUID entityVersion;
+ private final UUID entityVersion;
public UniqueValueImpl(
final CollectionScope scope, final Field field, Id entityId, final UUID version ) {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/CassandraThreadScheduler.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/CassandraThreadScheduler.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/CassandraThreadScheduler.java
index 7f9de19..512f0ec 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/CassandraThreadScheduler.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/CassandraThreadScheduler.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.rx;
@@ -20,16 +38,10 @@ import rx.Scheduler;
import rx.concurrency.Schedulers;
-/**
- *
- *
- */
public class CassandraThreadScheduler implements Provider<Scheduler> {
-
private static final Logger LOG = LoggerFactory.getLogger(CassandraThreadScheduler.class);
-
private final RxFig rxFig;
@@ -63,19 +75,21 @@ public class CassandraThreadScheduler implements Provider<Scheduler> {
/**
- * Create a threadpool that will reclaim unused threads after 60 seconds. It uses the max thread count set
- * here.
- * It intentionally uses the DynamicProperty, so that when it is updated, the listener updates the pool size
- * Additional allocation is trivial. Shrinking the size will require all currently executing threads to run
- * to completion, without allowing additional tasks to be queued.
- *
+ * Create a threadpool that will reclaim unused threads after 60 seconds.
+ * It uses the max thread count set here. It intentionally uses the
+ * DynamicProperty, so that when it is updated, the listener updates the
+ * pool size. Additional allocation is trivial. Shrinking the size
+ * will require all currently executing threads to run to completion,
+ * without allowing additional tasks to be queued.
*/
- final ThreadPoolExecutor pool = new ThreadPoolExecutor( 0, rxFig.getMaxThreadCount(), 60L, TimeUnit.SECONDS,
+ final ThreadPoolExecutor pool = new ThreadPoolExecutor(
+ 0, rxFig.getMaxThreadCount(), 60L, TimeUnit.SECONDS,
new SynchronousQueue<Runnable>(), factory, new ThreadPoolExecutor.AbortPolicy() );
- //if our max thread count is updated, we want to immediately update the pool. Per the javadoc
- //if the size is smaller, existing threads will continue to run until they become idle and time out
+ // if our max thread count is updated, we want to immediately update the pool.
+ // Per the javadoc if the size is smaller, existing threads will continue to run
+ // until they become idle and time out
rxFig.addPropertyChangeListener( new PropertyChangeListener() {
@Override
public void propertyChange( final PropertyChangeEvent evt ) {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/Concurrent.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/Concurrent.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/Concurrent.java
index 88e9fbb..f1c4ac2 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/Concurrent.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/Concurrent.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.rx;
@@ -12,15 +30,12 @@ import rx.util.functions.Func1;
/**
* A utility class that encapsulates many Funct1 operations that receive and emit the same type.
- * These functions are executed in parallel, then "zipped" into a single response. This is useful
- * when you want to perform operations on a single initial observable, then combine the result into a
- * single observable to continue the sequence
-
+ * These functions are executed in parallel, then "zipped" into a single response.
+ * This is useful when you want to perform operations on a single initial observable,
+ * then combine the result into a single observable to continue the sequence
*/
public class Concurrent<T, R> implements Func1<T, Observable<R>> {
-
-
private final Func1<T, R>[] concurrent;
private Concurrent( final Func1<T, R>[] concurrent ){
@@ -34,7 +49,9 @@ public class Concurrent<T, R> implements Func1<T, Observable<R>> {
//put all our observables together for concurrency
for( Func1<T, R> funct: concurrent){
- final Observable<R> observable = Observable.from(input).subscribeOn( Schedulers.threadPoolForIO() ).map( funct );
+ final Observable<R> observable =
+ Observable.from(input).subscribeOn(
+ Schedulers.threadPoolForIO() ).map( funct );
observables.add( observable );
}
@@ -53,16 +70,17 @@ public class Concurrent<T, R> implements Func1<T, Observable<R>> {
/**
- * Create an instance of concurrent execution. All functions specified in the list are invoked in parallel.
- * The results are then "zipped" into a single observable which is returned
- *
+ * Create an instance of concurrent execution. All functions specified
+ * in the list are invoked in parallel. The results are then "zipped"
+ * into a single observable which is returned
*
* @param observable The observable we're invoking on
* @param concurrent The concurrent operations we're invoking
* @return
*/
- public static <T, R> Observable<R> concurrent( final Observable<T> observable, final Func1<T, R>... concurrent ){
- return observable.mapMany( new Concurrent<T, R>( concurrent ));
+ public static <T, R> Observable<R> concurrent(
+ final Observable<T> observable, final Func1<T, R>... concurrent ){
+ return observable.mapMany( new Concurrent<T, R>( concurrent ));
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/RxFig.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/RxFig.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/RxFig.java
index 3519598..9751a9f 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/RxFig.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/rx/RxFig.java
@@ -1,3 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.collection.rx;
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializer.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializer.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializer.java
index 94759af..b0417d2 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializer.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializer.java
@@ -1,8 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.builder;
import org.apache.usergrid.persistence.model.entity.Entity;
-import org.apache.usergrid.persistence.model.entity.Id;
/**
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/1aba6206/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializerFactory.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializerFactory.java b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializerFactory.java
index 325645e..1104b54 100644
--- a/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializerFactory.java
+++ b/stack/corepersistence/model/src/main/java/org/apache/usergrid/persistence/model/builder/EntitySerializerFactory.java
@@ -1,6 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
package org.apache.usergrid.persistence.model.builder;
-
import org.apache.usergrid.persistence.model.entity.Id;
@@ -18,5 +35,4 @@ public interface EntitySerializerFactory {
*/
<T> EntitySerializer<T> getSerializer(Id id);
-
}
[3/3] git commit: Prevent double debug logging.
Posted by sn...@apache.org.
Prevent double debug logging.
Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/8773a183
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/8773a183
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/8773a183
Branch: refs/heads/two-dot-o
Commit: 8773a183310181c2b6d8923cc550f5d916b90e73
Parents: 1aba620
Author: Dave Johnson <dm...@apigee.com>
Authored: Mon Jan 20 10:56:52 2014 -0500
Committer: Dave Johnson <dm...@apigee.com>
Committed: Mon Jan 20 10:56:52 2014 -0500
----------------------------------------------------------------------
stack/rest/src/test/resources/log4j.properties | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/8773a183/stack/rest/src/test/resources/log4j.properties
----------------------------------------------------------------------
diff --git a/stack/rest/src/test/resources/log4j.properties b/stack/rest/src/test/resources/log4j.properties
index c660adb..34e591b 100644
--- a/stack/rest/src/test/resources/log4j.properties
+++ b/stack/rest/src/test/resources/log4j.properties
@@ -39,4 +39,4 @@ log4j.logger.org.usergrid.rest.security.AllowAjaxFilter=WARN, stdout
log4j.logger.me.prettyprint.hector.api.beans.AbstractComposite=ERROR, stdout
-#log4j.logger.org.apache.cassandra.service.StorageProxy=DEBUG, stdout
\ No newline at end of file
+log4j.logger.org.usergrid.rest.management=DEBUG
\ No newline at end of file