Questions tagged [dynamodb-mapper]

42 questions
1
vote
0 answers

Dynamically compose DynamoDB Query Expression according to user input

I'm writing an API endpoint to allow users to list items according to the parameters they pass in on the request body. I want the partition key to be the only required parameter; clients will be allowed to pass zero or more key-value pairs to…
10110
  • 2,353
  • 1
  • 21
  • 37
1
vote
1 answer

DynamoDB config throws "Network is unreachable: connect" error when trying to connect from local

This might be a very silly question when it comes to dynamo DB. Well,to summarize the issue I have a dynamoDB set up in my project. (FYI, I have not setup a local dynamodb, I'm trying to connect to my remote db in lab environment) The configuration…
1
vote
1 answer

Ho to use contains function in DynamoDB with DynamoDBMapper Java?

I need to check list of data with contains function is DynamoDB. Following is my Java Code, List dataList = new ArrayList<>(); I am inserting the above list inside a JSON called Data. Map valueMap = new…
0
votes
1 answer

DynamoDB scan works but load fails

I'm new to DynamoDB and am having some trouble loading data from my database with my Java code. I can see from the DDB console that I'm successfully storing data in tables and reading it in through scan. But if I try to use load, things fail. Here's…
0
votes
1 answer

Getting ValidationException when saving DynamoDB entity using Spring Boot

I am working with SpringBoot application that does CRUD operation on aws dynamoDB, and I have entity class that has structure of the following // getter, setter, args, no args annotation here @DynamoDBTable(tableName = "TableName") public class…
0
votes
1 answer

How to search within a JSON document stored in DynamoDB

There is a DynamoDB table called 'Field', which has 'pageId' and 'config' fields. The 'config' field contains a list of JSON objects. Field entity @Data @DynamoDBTable(tableName = "field") public class Field{ @DynamoDBHashKey(attributeName =…
JiboOne
  • 1,438
  • 4
  • 22
  • 55
0
votes
1 answer

Spring Boot JSON decoding error: Unrecognized field even when DTO has the fields

I am new to Spring Boot and Java so excuse my ignorance. I tried Googling but they all point me to Jackson errors which is what this is but I guess I am using Jackson implicitly by using @RequestBody annotation in my controller (correct me if I am…
streetsoldier
  • 1,259
  • 1
  • 14
  • 32
0
votes
1 answer

Update dynamodb attribute with long data type using dynamodb mapper

I have a Java POJO for writing into dynamodb. The DynamoDB is being updated by 2 different AWS lambdas from 2 different AWS SQS. I am using dynamoDBMapper to save record into dynamodb. The mapper config looks like below DynamoDBMapperConfig…
0
votes
1 answer

DynamoDB Mapper SaveExpression not throwing ConditionalCheckFailedException when record already exists

I have a DynamoDB table which has 3 attributes(partition key - id, sortkey - orderId, info). I am trying to write into DynamoDB if the record does not exist(either the partition key or the sort key) already. My code snippet as below public void…
0
votes
0 answers

Scala help. DynamoDBMappingException: could not unconvert attribute

I defined the following table in Scala. When I ran a test to query data from the dynamodb table, it throws exceptions: com.amazonaws.services.dynamodbv2.datamodeling. DynamoDBMappingException : TsuIntersectionRecord[comments]; could not unconvert…
Happy
  • 121
  • 1
  • 8
0
votes
1 answer

The number of conditions on the keys is invalid - Error in dynamo item update using DynamoDBMapper

I am new in dynamo db. I am trying to update the dynamo item amt attribute using the following expression. TransactionWriteRequest transactionWriteRequest = new TransactionWriteRequest(); HashMap attributeValues = new…
Shailendra
  • 528
  • 2
  • 10
  • 21
0
votes
1 answer

dynamoDb The provided key element does not match the schema error

I have a dynamoDb table with only hashKey. I am trying to insert a record by using dynamoDbMapper.save method. Although there is no mismatch in key, I am receiving following error. The provided key element does not match the schema (Service:…
user1474111
  • 1,356
  • 3
  • 23
  • 47
0
votes
1 answer

DynamoDB not fetching all entries in case of two autogenerated attributes

I have a crud application which uses DynamoDb, it has a model class containing two autogenerated attributes, one for primary key and another for timestamp. I am using scan() function of DynamoDbMapper to getAll entries from the db but getting below…
0
votes
0 answers

How to append element to a list attribute in dynamodb using dynamodb mapper?

I have a entity which looks like public class MyEntity { @DynamoDBHashKey private String myHashKey; @DynamoDBRangeKey private String myRangeKey; @DynamoDBAttribute private List myObjectsList; ... } Previously I used a…
n3eq
  • 15
  • 5
0
votes
1 answer

Search DynamoDB column for a specific string using DynamoDBMapper

I am using DynamoDBMapper to scan a a table, specifically a column named "title". I should be returned a list of blogs that contains a string passed into the scanExpression. This is code I wrote about a year and a half ago which I remember working.…