title: @DynamoDBIndexHashKey must specify one of HASH GSI name/names
body: <p>My Class is as Follows </p>
  
  <pre><code>@DynamoDBTable(tableName = LogConstant.TableName)
  public class Journal {
  
  @DynamoDBIndexHashKey(attributeName = "event_type")
  private String eventType;
  
  @DynamoDBIndexHashKey(attributeName = "user_id",globalSecondaryIndexName = LogConstant.GlobalUserIdIndex)
  private String userId;
  
  @DynamoDBIndexHashKey(attributeName = "user_identifier", globalSecondaryIndexName = LogConstant.GlobalUserIdentifierIndex)
  private String userIdentifier;
  
  @DynamoDBIndexHashKey(attributeName = "order_id", globalSecondaryIndexName = LogConstant.GlobalOrderIdIndex)
  private String orderId;
  
  @DynamoDBTypeConvertedEnum
  @DynamoDBAttribute(attributeName = "generated_by")
  private GenertionType generatedBy;
  
  @DynamoDBTypeConvertedEnum
  @DynamoDBHashKey(attributeName = "interacting_service")
  private InteractingService interactingSerice;
  
  @DynamoDBAttribute(attributeName = "agent")
  private String agent;
  
  @DynamoDBAttribute(attributeName = "content")
  private String content;
  
  @DynamoDBRangeKey
  @DynamoDBIndexRangeKey(attributeName = "created_at",
          globalSecondaryIndexNames = {LogConstant.GlobalUserIdIndex,LogConstant.GlobalUserIdentifierIndex,LogConstant.GlobalOrderIdIndex})
  private String createdAt;
  </code></pre>
  
  <p>The service getting the search result is </p>
  
  <pre><code>DynamoDBQueryExpression&lt;Journal&gt; expression = new 
  DynamoDBQueryExpression&lt;Journal&gt;()
              .withIndexName(LogConstant.GlobalUserIdIndex)
              .withConsistentRead(false)
              .withHashKeyValues(journal);
  
      TableDescription table = DynamoDbStarter.getDynamoDB().getTable(LogConstant.TableName).describe();
  
      return DynamoDbStarter.getDynamoDBMapper().query(Journal.class, expression);
  </code></pre>
  
  <p>Even Though the insert is working normally but during fetching the result I am getting an exception</p>
  
  <pre><code>com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMappingException: @DynamoDBIndexHashKey must specify one of HASH GSI name/names
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardAnnotationMaps$FieldMap.globalSecondaryIndexNames(StandardAnnotationMaps.java:345) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMapperFieldModel$Properties$Immutable.&lt;init&gt;(DynamoDBMapperFieldModel.java:459) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardBeanProperties$Bean.&lt;init&gt;(StandardBeanProperties.java:92) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardBeanProperties$Bean.&lt;init&gt;(StandardBeanProperties.java:86) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardBeanProperties$BeanMap.putOrFlatten(StandardBeanProperties.java:217) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardBeanProperties$BeanMap.putAll(StandardBeanProperties.java:207) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardBeanProperties$BeanMap.&lt;init&gt;(StandardBeanProperties.java:198) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardBeanProperties$CachedBeans.getBeans(StandardBeanProperties.java:55) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardBeanProperties$CachedBeans.access$100(StandardBeanProperties.java:48) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardBeanProperties.of(StandardBeanProperties.java:42) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardModelFactories$TableBuilder.&lt;init&gt;(StandardModelFactories.java:132) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardModelFactories$TableBuilder.&lt;init&gt;(StandardModelFactories.java:116) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.StandardModelFactories$StandardTableFactory.getTable(StandardModelFactories.java:107) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMapper.getTableModel(DynamoDBMapper.java:393) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMapper.createQueryRequestFromExpression(DynamoDBMapper.java:1626) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMapper.query(DynamoDBMapper.java:1503) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.amazonaws.services.dynamodbv2.datamodeling.AbstractDynamoDBMapper.query(AbstractDynamoDBMapper.java:265) ~[aws-java-sdk-dynamodb-1.11.172.jar:na]
  at com.furlenco.platform.loggingservice.service.impl.LogServiceimpl.getLogsBasedOnSecondaryIndexUserId(LogServiceimpl.java:86) ~[classes/:na]
  at com.furlenco.platform.loggingservice.service.impl.LogServiceimpl.getEventLogsForUserId(LogServiceimpl.java:67) ~[classes/:na]
  </code></pre>
  
  <p>I have table with hash key as interacting_service and range key as CreatedDate. I am trying to fetch result by GSI But somehow It is resulting in an exception
  Can Somebody see what is it that I am doing wrong</p>