You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by sc...@apache.org on 2016/10/16 22:26:31 UTC
[49/51] [abbrv] airavata git commit: fixing id issues
http://git-wip-us.apache.org/repos/asf/airavata/blob/b6e07d7b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/GroupMembership.java
----------------------------------------------------------------------
diff --git a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/GroupMembership.java b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/GroupMembership.java
index 9fe3043..819dd0d 100644
--- a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/GroupMembership.java
+++ b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/GroupMembership.java
@@ -38,15 +38,16 @@ import org.slf4j.LoggerFactory;
* <p>System internal data type to map group memberships</p>
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-14")
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-16")
public class GroupMembership implements org.apache.thrift.TBase<GroupMembership, GroupMembership._Fields>, java.io.Serializable, Cloneable, Comparable<GroupMembership> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("GroupMembership");
private static final org.apache.thrift.protocol.TField PARENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("parentId", org.apache.thrift.protocol.TType.STRING, (short)1);
private static final org.apache.thrift.protocol.TField CHILD_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("childId", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final org.apache.thrift.protocol.TField CHILD_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("childType", org.apache.thrift.protocol.TType.I32, (short)3);
- private static final org.apache.thrift.protocol.TField CREATED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("createdTime", org.apache.thrift.protocol.TType.I64, (short)4);
- private static final org.apache.thrift.protocol.TField UPDATED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("updatedTime", org.apache.thrift.protocol.TType.I64, (short)5);
+ private static final org.apache.thrift.protocol.TField DOMAIN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("domainId", org.apache.thrift.protocol.TType.STRING, (short)3);
+ private static final org.apache.thrift.protocol.TField CHILD_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("childType", org.apache.thrift.protocol.TType.I32, (short)4);
+ private static final org.apache.thrift.protocol.TField CREATED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("createdTime", org.apache.thrift.protocol.TType.I64, (short)5);
+ private static final org.apache.thrift.protocol.TField UPDATED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("updatedTime", org.apache.thrift.protocol.TType.I64, (short)6);
private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
@@ -56,6 +57,7 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
public String parentId; // optional
public String childId; // optional
+ public String domainId; // optional
/**
*
* @see GroupChildType
@@ -68,13 +70,14 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
PARENT_ID((short)1, "parentId"),
CHILD_ID((short)2, "childId"),
+ DOMAIN_ID((short)3, "domainId"),
/**
*
* @see GroupChildType
*/
- CHILD_TYPE((short)3, "childType"),
- CREATED_TIME((short)4, "createdTime"),
- UPDATED_TIME((short)5, "updatedTime");
+ CHILD_TYPE((short)4, "childType"),
+ CREATED_TIME((short)5, "createdTime"),
+ UPDATED_TIME((short)6, "updatedTime");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
@@ -93,11 +96,13 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
return PARENT_ID;
case 2: // CHILD_ID
return CHILD_ID;
- case 3: // CHILD_TYPE
+ case 3: // DOMAIN_ID
+ return DOMAIN_ID;
+ case 4: // CHILD_TYPE
return CHILD_TYPE;
- case 4: // CREATED_TIME
+ case 5: // CREATED_TIME
return CREATED_TIME;
- case 5: // UPDATED_TIME
+ case 6: // UPDATED_TIME
return UPDATED_TIME;
default:
return null;
@@ -142,7 +147,7 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
private static final int __CREATEDTIME_ISSET_ID = 0;
private static final int __UPDATEDTIME_ISSET_ID = 1;
private byte __isset_bitfield = 0;
- private static final _Fields optionals[] = {_Fields.PARENT_ID,_Fields.CHILD_ID,_Fields.CHILD_TYPE,_Fields.CREATED_TIME,_Fields.UPDATED_TIME};
+ private static final _Fields optionals[] = {_Fields.PARENT_ID,_Fields.CHILD_ID,_Fields.DOMAIN_ID,_Fields.CHILD_TYPE,_Fields.CREATED_TIME,_Fields.UPDATED_TIME};
public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
static {
Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
@@ -150,6 +155,8 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.CHILD_ID, new org.apache.thrift.meta_data.FieldMetaData("childId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
+ tmpMap.put(_Fields.DOMAIN_ID, new org.apache.thrift.meta_data.FieldMetaData("domainId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.CHILD_TYPE, new org.apache.thrift.meta_data.FieldMetaData("childType", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, GroupChildType.class)));
tmpMap.put(_Fields.CREATED_TIME, new org.apache.thrift.meta_data.FieldMetaData("createdTime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -174,6 +181,9 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
if (other.isSetChildId()) {
this.childId = other.childId;
}
+ if (other.isSetDomainId()) {
+ this.domainId = other.domainId;
+ }
if (other.isSetChildType()) {
this.childType = other.childType;
}
@@ -189,6 +199,7 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
public void clear() {
this.parentId = null;
this.childId = null;
+ this.domainId = null;
this.childType = null;
setCreatedTimeIsSet(false);
this.createdTime = 0;
@@ -244,6 +255,30 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
}
}
+ public String getDomainId() {
+ return this.domainId;
+ }
+
+ public GroupMembership setDomainId(String domainId) {
+ this.domainId = domainId;
+ return this;
+ }
+
+ public void unsetDomainId() {
+ this.domainId = null;
+ }
+
+ /** Returns true if field domainId is set (has been assigned a value) and false otherwise */
+ public boolean isSetDomainId() {
+ return this.domainId != null;
+ }
+
+ public void setDomainIdIsSet(boolean value) {
+ if (!value) {
+ this.domainId = null;
+ }
+ }
+
/**
*
* @see GroupChildType
@@ -340,6 +375,14 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
}
break;
+ case DOMAIN_ID:
+ if (value == null) {
+ unsetDomainId();
+ } else {
+ setDomainId((String)value);
+ }
+ break;
+
case CHILD_TYPE:
if (value == null) {
unsetChildType();
@@ -375,6 +418,9 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
case CHILD_ID:
return getChildId();
+ case DOMAIN_ID:
+ return getDomainId();
+
case CHILD_TYPE:
return getChildType();
@@ -399,6 +445,8 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
return isSetParentId();
case CHILD_ID:
return isSetChildId();
+ case DOMAIN_ID:
+ return isSetDomainId();
case CHILD_TYPE:
return isSetChildType();
case CREATED_TIME:
@@ -440,6 +488,15 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
return false;
}
+ boolean this_present_domainId = true && this.isSetDomainId();
+ boolean that_present_domainId = true && that.isSetDomainId();
+ if (this_present_domainId || that_present_domainId) {
+ if (!(this_present_domainId && that_present_domainId))
+ return false;
+ if (!this.domainId.equals(that.domainId))
+ return false;
+ }
+
boolean this_present_childType = true && this.isSetChildType();
boolean that_present_childType = true && that.isSetChildType();
if (this_present_childType || that_present_childType) {
@@ -484,6 +541,11 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
if (present_childId)
list.add(childId);
+ boolean present_domainId = true && (isSetDomainId());
+ list.add(present_domainId);
+ if (present_domainId)
+ list.add(domainId);
+
boolean present_childType = true && (isSetChildType());
list.add(present_childType);
if (present_childType)
@@ -530,6 +592,16 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
return lastComparison;
}
}
+ lastComparison = Boolean.valueOf(isSetDomainId()).compareTo(other.isSetDomainId());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetDomainId()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.domainId, other.domainId);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
lastComparison = Boolean.valueOf(isSetChildType()).compareTo(other.isSetChildType());
if (lastComparison != 0) {
return lastComparison;
@@ -599,6 +671,16 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
}
first = false;
}
+ if (isSetDomainId()) {
+ if (!first) sb.append(", ");
+ sb.append("domainId:");
+ if (this.domainId == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.domainId);
+ }
+ first = false;
+ }
if (isSetChildType()) {
if (!first) sb.append(", ");
sb.append("childType:");
@@ -682,7 +764,15 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 3: // CHILD_TYPE
+ case 3: // DOMAIN_ID
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+ struct.domainId = iprot.readString();
+ struct.setDomainIdIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ case 4: // CHILD_TYPE
if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
struct.childType = org.apache.airavata.sharing.registry.models.GroupChildType.findByValue(iprot.readI32());
struct.setChildTypeIsSet(true);
@@ -690,7 +780,7 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 4: // CREATED_TIME
+ case 5: // CREATED_TIME
if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
struct.createdTime = iprot.readI64();
struct.setCreatedTimeIsSet(true);
@@ -698,7 +788,7 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 5: // UPDATED_TIME
+ case 6: // UPDATED_TIME
if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
struct.updatedTime = iprot.readI64();
struct.setUpdatedTimeIsSet(true);
@@ -735,6 +825,13 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
oprot.writeFieldEnd();
}
}
+ if (struct.domainId != null) {
+ if (struct.isSetDomainId()) {
+ oprot.writeFieldBegin(DOMAIN_ID_FIELD_DESC);
+ oprot.writeString(struct.domainId);
+ oprot.writeFieldEnd();
+ }
+ }
if (struct.childType != null) {
if (struct.isSetChildType()) {
oprot.writeFieldBegin(CHILD_TYPE_FIELD_DESC);
@@ -776,22 +873,28 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
if (struct.isSetChildId()) {
optionals.set(1);
}
- if (struct.isSetChildType()) {
+ if (struct.isSetDomainId()) {
optionals.set(2);
}
- if (struct.isSetCreatedTime()) {
+ if (struct.isSetChildType()) {
optionals.set(3);
}
- if (struct.isSetUpdatedTime()) {
+ if (struct.isSetCreatedTime()) {
optionals.set(4);
}
- oprot.writeBitSet(optionals, 5);
+ if (struct.isSetUpdatedTime()) {
+ optionals.set(5);
+ }
+ oprot.writeBitSet(optionals, 6);
if (struct.isSetParentId()) {
oprot.writeString(struct.parentId);
}
if (struct.isSetChildId()) {
oprot.writeString(struct.childId);
}
+ if (struct.isSetDomainId()) {
+ oprot.writeString(struct.domainId);
+ }
if (struct.isSetChildType()) {
oprot.writeI32(struct.childType.getValue());
}
@@ -806,7 +909,7 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, GroupMembership struct) throws org.apache.thrift.TException {
TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(5);
+ BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.parentId = iprot.readString();
struct.setParentIdIsSet(true);
@@ -816,14 +919,18 @@ public class GroupMembership implements org.apache.thrift.TBase<GroupMembership,
struct.setChildIdIsSet(true);
}
if (incoming.get(2)) {
+ struct.domainId = iprot.readString();
+ struct.setDomainIdIsSet(true);
+ }
+ if (incoming.get(3)) {
struct.childType = org.apache.airavata.sharing.registry.models.GroupChildType.findByValue(iprot.readI32());
struct.setChildTypeIsSet(true);
}
- if (incoming.get(3)) {
+ if (incoming.get(4)) {
struct.createdTime = iprot.readI64();
struct.setCreatedTimeIsSet(true);
}
- if (incoming.get(4)) {
+ if (incoming.get(5)) {
struct.updatedTime = iprot.readI64();
struct.setUpdatedTimeIsSet(true);
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/b6e07d7b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/PermissionType.java
----------------------------------------------------------------------
diff --git a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/PermissionType.java b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/PermissionType.java
index 2952f7a..9736a85 100644
--- a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/PermissionType.java
+++ b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/PermissionType.java
@@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
/**
* <p>Object for creating client defined permission type</p>
- * <li>permissionTypeId : System generated permission type id. In the current implementation it will of the form domainId:name</li>
+ * <li><b>permissionTypeId</b> : Permission type id provided by the client</li>
* <li><b>domainId</b> : Domain id</li>
* <li><b>name</b> : Single word name for the permission</li>
* <li>description : Short description for the permission type</li>
@@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
* <li>updatedTime : Will be set by the system</li>
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-14")
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-16")
public class PermissionType implements org.apache.thrift.TBase<PermissionType, PermissionType._Fields>, java.io.Serializable, Cloneable, Comparable<PermissionType> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("PermissionType");
@@ -166,8 +166,6 @@ public class PermissionType implements org.apache.thrift.TBase<PermissionType, P
}
public PermissionType() {
- this.permissionTypeId = "DO_NOT_SET_AT_CLIENTS_ID";
-
}
/**
@@ -197,8 +195,7 @@ public class PermissionType implements org.apache.thrift.TBase<PermissionType, P
@Override
public void clear() {
- this.permissionTypeId = "DO_NOT_SET_AT_CLIENTS_ID";
-
+ this.permissionTypeId = null;
this.domainId = null;
this.name = null;
this.description = null;
http://git-wip-us.apache.org/repos/asf/airavata/blob/b6e07d7b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SearchCriteria.java
----------------------------------------------------------------------
diff --git a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SearchCriteria.java b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SearchCriteria.java
index 71fd003..faffae0 100644
--- a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SearchCriteria.java
+++ b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SearchCriteria.java
@@ -41,7 +41,7 @@ import org.slf4j.LoggerFactory;
* <li><b>searchCondition</b> : EQUAL, LIKE etc..</li>
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-14")
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-16")
public class SearchCriteria implements org.apache.thrift.TBase<SearchCriteria, SearchCriteria._Fields>, java.io.Serializable, Cloneable, Comparable<SearchCriteria> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("SearchCriteria");
http://git-wip-us.apache.org/repos/asf/airavata/blob/b6e07d7b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/Sharing.java
----------------------------------------------------------------------
diff --git a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/Sharing.java b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/Sharing.java
index ed1cd61..753fe74 100644
--- a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/Sharing.java
+++ b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/Sharing.java
@@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
* <p>This is an internal enum type for managing sharings</p>
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-14")
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-16")
public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields>, java.io.Serializable, Cloneable, Comparable<Sharing> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("Sharing");
@@ -46,9 +46,10 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
private static final org.apache.thrift.protocol.TField ENTITY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("entityId", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField GROUP_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("groupId", org.apache.thrift.protocol.TType.STRING, (short)3);
private static final org.apache.thrift.protocol.TField SHARING_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("sharingType", org.apache.thrift.protocol.TType.I32, (short)4);
- private static final org.apache.thrift.protocol.TField INHERITED_PARENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("inheritedParentId", org.apache.thrift.protocol.TType.STRING, (short)5);
- private static final org.apache.thrift.protocol.TField CREATED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("createdTime", org.apache.thrift.protocol.TType.I64, (short)6);
- private static final org.apache.thrift.protocol.TField UPDATED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("updatedTime", org.apache.thrift.protocol.TType.I64, (short)7);
+ private static final org.apache.thrift.protocol.TField DOMAIN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("domainId", org.apache.thrift.protocol.TType.STRING, (short)5);
+ private static final org.apache.thrift.protocol.TField INHERITED_PARENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("inheritedParentId", org.apache.thrift.protocol.TType.STRING, (short)6);
+ private static final org.apache.thrift.protocol.TField CREATED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("createdTime", org.apache.thrift.protocol.TType.I64, (short)7);
+ private static final org.apache.thrift.protocol.TField UPDATED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("updatedTime", org.apache.thrift.protocol.TType.I64, (short)8);
private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
@@ -64,6 +65,7 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
* @see SharingType
*/
public SharingType sharingType; // optional
+ public String domainId; // optional
public String inheritedParentId; // optional
public long createdTime; // optional
public long updatedTime; // optional
@@ -78,9 +80,10 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
* @see SharingType
*/
SHARING_TYPE((short)4, "sharingType"),
- INHERITED_PARENT_ID((short)5, "inheritedParentId"),
- CREATED_TIME((short)6, "createdTime"),
- UPDATED_TIME((short)7, "updatedTime");
+ DOMAIN_ID((short)5, "domainId"),
+ INHERITED_PARENT_ID((short)6, "inheritedParentId"),
+ CREATED_TIME((short)7, "createdTime"),
+ UPDATED_TIME((short)8, "updatedTime");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
@@ -103,11 +106,13 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
return GROUP_ID;
case 4: // SHARING_TYPE
return SHARING_TYPE;
- case 5: // INHERITED_PARENT_ID
+ case 5: // DOMAIN_ID
+ return DOMAIN_ID;
+ case 6: // INHERITED_PARENT_ID
return INHERITED_PARENT_ID;
- case 6: // CREATED_TIME
+ case 7: // CREATED_TIME
return CREATED_TIME;
- case 7: // UPDATED_TIME
+ case 8: // UPDATED_TIME
return UPDATED_TIME;
default:
return null;
@@ -152,7 +157,7 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
private static final int __CREATEDTIME_ISSET_ID = 0;
private static final int __UPDATEDTIME_ISSET_ID = 1;
private byte __isset_bitfield = 0;
- private static final _Fields optionals[] = {_Fields.PERMISSION_TYPE_ID,_Fields.ENTITY_ID,_Fields.GROUP_ID,_Fields.SHARING_TYPE,_Fields.INHERITED_PARENT_ID,_Fields.CREATED_TIME,_Fields.UPDATED_TIME};
+ private static final _Fields optionals[] = {_Fields.PERMISSION_TYPE_ID,_Fields.ENTITY_ID,_Fields.GROUP_ID,_Fields.SHARING_TYPE,_Fields.DOMAIN_ID,_Fields.INHERITED_PARENT_ID,_Fields.CREATED_TIME,_Fields.UPDATED_TIME};
public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
static {
Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
@@ -164,6 +169,8 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SHARING_TYPE, new org.apache.thrift.meta_data.FieldMetaData("sharingType", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, SharingType.class)));
+ tmpMap.put(_Fields.DOMAIN_ID, new org.apache.thrift.meta_data.FieldMetaData("domainId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.INHERITED_PARENT_ID, new org.apache.thrift.meta_data.FieldMetaData("inheritedParentId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.CREATED_TIME, new org.apache.thrift.meta_data.FieldMetaData("createdTime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -194,6 +201,9 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
if (other.isSetSharingType()) {
this.sharingType = other.sharingType;
}
+ if (other.isSetDomainId()) {
+ this.domainId = other.domainId;
+ }
if (other.isSetInheritedParentId()) {
this.inheritedParentId = other.inheritedParentId;
}
@@ -211,6 +221,7 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
this.entityId = null;
this.groupId = null;
this.sharingType = null;
+ this.domainId = null;
this.inheritedParentId = null;
setCreatedTimeIsSet(false);
this.createdTime = 0;
@@ -322,6 +333,30 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
}
}
+ public String getDomainId() {
+ return this.domainId;
+ }
+
+ public Sharing setDomainId(String domainId) {
+ this.domainId = domainId;
+ return this;
+ }
+
+ public void unsetDomainId() {
+ this.domainId = null;
+ }
+
+ /** Returns true if field domainId is set (has been assigned a value) and false otherwise */
+ public boolean isSetDomainId() {
+ return this.domainId != null;
+ }
+
+ public void setDomainIdIsSet(boolean value) {
+ if (!value) {
+ this.domainId = null;
+ }
+ }
+
public String getInheritedParentId() {
return this.inheritedParentId;
}
@@ -426,6 +461,14 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
}
break;
+ case DOMAIN_ID:
+ if (value == null) {
+ unsetDomainId();
+ } else {
+ setDomainId((String)value);
+ }
+ break;
+
case INHERITED_PARENT_ID:
if (value == null) {
unsetInheritedParentId();
@@ -467,6 +510,9 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
case SHARING_TYPE:
return getSharingType();
+ case DOMAIN_ID:
+ return getDomainId();
+
case INHERITED_PARENT_ID:
return getInheritedParentId();
@@ -495,6 +541,8 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
return isSetGroupId();
case SHARING_TYPE:
return isSetSharingType();
+ case DOMAIN_ID:
+ return isSetDomainId();
case INHERITED_PARENT_ID:
return isSetInheritedParentId();
case CREATED_TIME:
@@ -554,6 +602,15 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
return false;
}
+ boolean this_present_domainId = true && this.isSetDomainId();
+ boolean that_present_domainId = true && that.isSetDomainId();
+ if (this_present_domainId || that_present_domainId) {
+ if (!(this_present_domainId && that_present_domainId))
+ return false;
+ if (!this.domainId.equals(that.domainId))
+ return false;
+ }
+
boolean this_present_inheritedParentId = true && this.isSetInheritedParentId();
boolean that_present_inheritedParentId = true && that.isSetInheritedParentId();
if (this_present_inheritedParentId || that_present_inheritedParentId) {
@@ -608,6 +665,11 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
if (present_sharingType)
list.add(sharingType.getValue());
+ boolean present_domainId = true && (isSetDomainId());
+ list.add(present_domainId);
+ if (present_domainId)
+ list.add(domainId);
+
boolean present_inheritedParentId = true && (isSetInheritedParentId());
list.add(present_inheritedParentId);
if (present_inheritedParentId)
@@ -674,6 +736,16 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
return lastComparison;
}
}
+ lastComparison = Boolean.valueOf(isSetDomainId()).compareTo(other.isSetDomainId());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetDomainId()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.domainId, other.domainId);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
lastComparison = Boolean.valueOf(isSetInheritedParentId()).compareTo(other.isSetInheritedParentId());
if (lastComparison != 0) {
return lastComparison;
@@ -763,6 +835,16 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
}
first = false;
}
+ if (isSetDomainId()) {
+ if (!first) sb.append(", ");
+ sb.append("domainId:");
+ if (this.domainId == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.domainId);
+ }
+ first = false;
+ }
if (isSetInheritedParentId()) {
if (!first) sb.append(", ");
sb.append("inheritedParentId:");
@@ -862,7 +944,15 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 5: // INHERITED_PARENT_ID
+ case 5: // DOMAIN_ID
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+ struct.domainId = iprot.readString();
+ struct.setDomainIdIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ case 6: // INHERITED_PARENT_ID
if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
struct.inheritedParentId = iprot.readString();
struct.setInheritedParentIdIsSet(true);
@@ -870,7 +960,7 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 6: // CREATED_TIME
+ case 7: // CREATED_TIME
if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
struct.createdTime = iprot.readI64();
struct.setCreatedTimeIsSet(true);
@@ -878,7 +968,7 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 7: // UPDATED_TIME
+ case 8: // UPDATED_TIME
if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
struct.updatedTime = iprot.readI64();
struct.setUpdatedTimeIsSet(true);
@@ -929,6 +1019,13 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
oprot.writeFieldEnd();
}
}
+ if (struct.domainId != null) {
+ if (struct.isSetDomainId()) {
+ oprot.writeFieldBegin(DOMAIN_ID_FIELD_DESC);
+ oprot.writeString(struct.domainId);
+ oprot.writeFieldEnd();
+ }
+ }
if (struct.inheritedParentId != null) {
if (struct.isSetInheritedParentId()) {
oprot.writeFieldBegin(INHERITED_PARENT_ID_FIELD_DESC);
@@ -976,16 +1073,19 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
if (struct.isSetSharingType()) {
optionals.set(3);
}
- if (struct.isSetInheritedParentId()) {
+ if (struct.isSetDomainId()) {
optionals.set(4);
}
- if (struct.isSetCreatedTime()) {
+ if (struct.isSetInheritedParentId()) {
optionals.set(5);
}
- if (struct.isSetUpdatedTime()) {
+ if (struct.isSetCreatedTime()) {
optionals.set(6);
}
- oprot.writeBitSet(optionals, 7);
+ if (struct.isSetUpdatedTime()) {
+ optionals.set(7);
+ }
+ oprot.writeBitSet(optionals, 8);
if (struct.isSetPermissionTypeId()) {
oprot.writeString(struct.permissionTypeId);
}
@@ -998,6 +1098,9 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
if (struct.isSetSharingType()) {
oprot.writeI32(struct.sharingType.getValue());
}
+ if (struct.isSetDomainId()) {
+ oprot.writeString(struct.domainId);
+ }
if (struct.isSetInheritedParentId()) {
oprot.writeString(struct.inheritedParentId);
}
@@ -1012,7 +1115,7 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, Sharing struct) throws org.apache.thrift.TException {
TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(7);
+ BitSet incoming = iprot.readBitSet(8);
if (incoming.get(0)) {
struct.permissionTypeId = iprot.readString();
struct.setPermissionTypeIdIsSet(true);
@@ -1030,14 +1133,18 @@ public class Sharing implements org.apache.thrift.TBase<Sharing, Sharing._Fields
struct.setSharingTypeIsSet(true);
}
if (incoming.get(4)) {
+ struct.domainId = iprot.readString();
+ struct.setDomainIdIsSet(true);
+ }
+ if (incoming.get(5)) {
struct.inheritedParentId = iprot.readString();
struct.setInheritedParentIdIsSet(true);
}
- if (incoming.get(5)) {
+ if (incoming.get(6)) {
struct.createdTime = iprot.readI64();
struct.setCreatedTimeIsSet(true);
}
- if (incoming.get(6)) {
+ if (incoming.get(7)) {
struct.updatedTime = iprot.readI64();
struct.setUpdatedTimeIsSet(true);
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/b6e07d7b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SharingRegistryException.java
----------------------------------------------------------------------
diff --git a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SharingRegistryException.java b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SharingRegistryException.java
index 06fa123..61e08aa 100644
--- a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SharingRegistryException.java
+++ b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/SharingRegistryException.java
@@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
* <p>Exception model used in the sharing registry service</p>
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-14")
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-16")
public class SharingRegistryException extends TException implements org.apache.thrift.TBase<SharingRegistryException, SharingRegistryException._Fields>, java.io.Serializable, Cloneable, Comparable<SharingRegistryException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("SharingRegistryException");
http://git-wip-us.apache.org/repos/asf/airavata/blob/b6e07d7b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/User.java
----------------------------------------------------------------------
diff --git a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/User.java b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/User.java
index 65b5e60..34508f7 100644
--- a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/User.java
+++ b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/User.java
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
/**
* <p>User is the model used to register a user in the system. Minimal user information will be required to provide
* regarding the user.</p>
- * <li><b>userId</b> : Client provided user id. (The id is not system generated and it is a must to provide this id)</li>
+ * <li><b>userId</b> : User id provided by the client</li>
* <li><b>domainId</b> : Domain id for that user</li>
* <li><b>userName</b> : User name for the user</li>
* <li><b>firstName</b> : First name of the user</li>
@@ -48,7 +48,7 @@ import org.slf4j.LoggerFactory;
* <li>updatedTime : If client provides this value then the system will use it if not the current time will be set</li>
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-14")
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-16")
public class User implements org.apache.thrift.TBase<User, User._Fields>, java.io.Serializable, Cloneable, Comparable<User> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("User");
http://git-wip-us.apache.org/repos/asf/airavata/blob/b6e07d7b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/UserGroup.java
----------------------------------------------------------------------
diff --git a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/UserGroup.java b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/UserGroup.java
index 8edbcc1..484ea3b 100644
--- a/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/UserGroup.java
+++ b/modules/sharing-registry/sharing-registry-stubs/src/main/java/org/apache/airavata/sharing/registry/models/UserGroup.java
@@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
/**
* <p>User group is a collection of users.</p>
- * <li>groupId : System generated grouo id. In the current implementation this is of the form domainId:name</li>
+ * <li><b>groupId</b> : Group id provided by the client</li>
* <li><b>domainId</b> : Domain id for this user group</li>
* <li><b>name</b> : Name for the user group. should be one word</li>
* <li>description : Short description for the group.</li>
@@ -47,7 +47,7 @@ import org.slf4j.LoggerFactory;
* <li>updatedTime : Will be set by the system</li>
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-14")
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-10-16")
public class UserGroup implements org.apache.thrift.TBase<UserGroup, UserGroup._Fields>, java.io.Serializable, Cloneable, Comparable<UserGroup> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("UserGroup");
@@ -206,8 +206,6 @@ public class UserGroup implements org.apache.thrift.TBase<UserGroup, UserGroup._
}
public UserGroup() {
- this.groupId = "DO_NOT_SET_AT_CLIENTS_ID";
-
}
/**
@@ -246,8 +244,7 @@ public class UserGroup implements org.apache.thrift.TBase<UserGroup, UserGroup._
@Override
public void clear() {
- this.groupId = "DO_NOT_SET_AT_CLIENTS_ID";
-
+ this.groupId = null;
this.domainId = null;
this.name = null;
this.description = null;