You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
JavaScript Framework
React Native
Amplify APIs
DataStore
Amplify Version
v5
Amplify Categories
storage, api
Backend
Amplify CLI
Environment information
# Put output below this line
**Issue: AWS Amplify DataStore Sync Problem**
**Description**: The AWS Amplify DataStore is not functioning correctly when data is inserted using DataStore.save(). Occasionally, the data does not sync with the server and remains only in the local storage (DynamoDB). After some time, the data eventually syncs with the server.
**Library Versions:**
- @aws-amplify/datastore-storage-adapter: ^1.4.5
- aws-amplify: ^5.3.10
- react-native:0.68.2
Describe the bug
Issue: AWS Amplify DataStore Sync Problem
Description: The AWS Amplify DataStore is not functioning correctly when data is inserted using DataStore.save(). Occasionally, the data does not sync with the server and remains only in the local storage (DynamoDB). After some time, the data eventually syncs with the server.
Library Versions:
@aws-amplify/datastore-storage-adapter: ^1.4.5
aws-amplify: ^5.3.10
react-native:0.68.2
Expected behavior
All data is also synchronised via the datastore
Reproduction steps
Create data with DataStore and AWS GraphQL
Check the code logs
Check the data in DynamoDB, but note that there might be some issues or additional information to review
Hi @vijaykishan312 👋 thanks for raising this issue. I see that you are still using v5 of the aws-amplify library. Is there any reason you are not able to upgrade to v6?
If you have tried to upgrade, do you experience this issue on v6 or the latest version of aws-amplify as well?
Closing this issue as we have not heard back from you. If you are still experiencing this, please feel free to reply back and provide any information previously requested and we'd be happy to re-open the issue.
Before opening, please confirm:
JavaScript Framework
React Native
Amplify APIs
DataStore
Amplify Version
v5
Amplify Categories
storage, api
Backend
Amplify CLI
Environment information
Describe the bug
Issue: AWS Amplify DataStore Sync Problem
Description: The AWS Amplify DataStore is not functioning correctly when data is inserted using DataStore.save(). Occasionally, the data does not sync with the server and remains only in the local storage (DynamoDB). After some time, the data eventually syncs with the server.
Library Versions:
Expected behavior
All data is also synchronised via the datastore
Reproduction steps
Code Snippet
// Put your code below this line.
const dataCollection = {
sessionDuration: dataResponse[0]?.sessionDuration,
collectionStorage: dataResponse[0]?.collectionStorage,
currentStorageLocation: privousCollectionData[0]
?.previousCurrentStorageLocation
? privousCollectionData[0]?.previousCurrentStorageLocation
: dataResponse[0]?.currentStorageLocation,
CollectionUsedDate: null,
isCollectionUsed: false,
storeReferenceId: privousCollectionData[0]?.previousStoreReferenceId,
collectionUsedBy: '',
otherUsedMessage: null,
isActivityFinish: true,
collectionId: null,
id: privousCollectionData[i]?.id,
locationChangeDate:
privousCollectionData[0]?.previousLocationChangeDate,
storageExpiryAlert:
privousCollectionData[0]?.previousStorageExpiryAlert,
storageExpiry: privousCollectionData[0]?.previousStorageExpiry,
updatedAt: currentUTCTime(),
activityType: 'Collection',
activitySide: dataResponse[0]?.activitySide,
activityEndTime: privousCollectionData[0]?.previousActivityEndTime,
sessionEndTime: privousCollectionData[0]?.previousSessionEndTime,
previousStoreReferenceId: '',
previousStorageExpiryAlert: '',
previousLocationChangeDate: '',
previousCurrentStorageLocation:
privousCollectionData[0]?.previousCurrentStorageLocation,
previousStorageExpiry: '',
previousActivityEndTime: '',
previousSessionEndTime: '',
subjectId: '',
stashTotalFeed: '',
activityDoneVia: dataResponse[0]?.activityDoneVia,
activityDuration:dataResponse[0]?.activityDuration,
sessionStartTime:dataResponse[0]?.sessionStartTime,
subjectAvatarName:dataResponse[0]?.subjectAvatarName,
activityStartTime:dataResponse[0]?.activityStartTime,
unitOfMeasurement:dataResponse[0]?.unitOfMeasurement,
appId:dataResponse[0]?.appId,
_deleted:dataResponse[0]?._deleted,
preStorageLocation:dataResponse[0]?.preStorageLocation,
stashUsedCollectionId:dataResponse[0]?.stashUsedCollectionId,
stashStart:dataResponse[0]?.stashStart,
vijay:dataResponse[0]?.vijay,
createdAt:dataResponse[0]?.createdAt,
deviceType:dataResponse[0]?.deviceType,
_lastChangedAt:dataResponse[0]?._lastChangedAt,
isSync:dataResponse[0]?.isSync,
owner:dataResponse[0]?.owner,
collectionStorageUsed:String(dataResponse[0]?.collectionStorageUsed),
sessionId:dataResponse[0]?.sessionId,
};
// Code for data save
const response = await DataStore.save(new Activity(dataCollection))
Log output
aws-exports.js
No response
Manual configuration
No response
Additional configuration
No response
Mobile Device
iPhone 15, Pixel 5A
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response
The text was updated successfully, but these errors were encountered: