Skip to content

Conversation

@lawmicha
Copy link
Contributor

@lawmicha lawmicha commented Jan 9, 2023

Issue #, if available:

Description of changes:
Merging data-dev-preview into main. This mainly consists of DataStore/API Lazy Loading and Custom selection sets.

Check points: (check or cross out if not relevant)

  • Added new tests to cover change, if needed
  • Build succeeds with all target using Swift Package Manager
  • All unit tests pass
  • All integration tests pass
  • Security oriented best practices and standards are followed (e.g. using input sanitization, principle of least privilege, etc)
  • Documentation update for the change if required (feat(cli): migration guide for lazy loading and custom selection set feature flag docs#4934)
  • PR title conforms to conventional commit style
  • If breaking change, documentation/changelog update with migration instructions

DataStore checkpoints (check when completed)

  • Ran AWSDataStorePluginIntegrationTests
  • Ran AWSDataStorePluginV2Tests
  • Ran AWSDataStorePluginMultiAuthTests (https://github.com/aws-amplify/amplify-swift/actions/runs/4119377763)
  • Ran AWSDataStorePluginCPKTests
  • Ran AWSDataStorePluginAuthCognitoTests
  • Ran AWSDataStorePluginAuthIAMTests
  • Ran AWSDataStorePluginLazyLoadTests
  • Ran AWSAPIPluginLazyLoadTests
  • Ran AWSAPIPluginFunctionalTests
  • Ran AWSAPIPluginGraphQLIAMTests
  • Ran AWSAPIPluginGraphQLLambdaAuthTests
  • Ran AWSAPIPluginGraphQLUserPoolTests

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@lawmicha lawmicha requested review from a team as code owners January 9, 2023 14:58
@lawmicha lawmicha marked this pull request as draft January 9, 2023 15:03
@lawmicha lawmicha temporarily deployed to IntegrationTest January 25, 2023 19:49 — with GitHub Actions Inactive
@lawmicha lawmicha temporarily deployed to IntegrationTest January 25, 2023 19:49 — with GitHub Actions Inactive
@5d 5d temporarily deployed to IntegrationTest February 1, 2023 18:14 — with GitHub Actions Inactive
@5d 5d temporarily deployed to IntegrationTest February 1, 2023 18:15 — with GitHub Actions Inactive
@lawmicha lawmicha temporarily deployed to IntegrationTest February 1, 2023 18:32 — with GitHub Actions Inactive
@lawmicha lawmicha temporarily deployed to IntegrationTest February 1, 2023 18:32 — with GitHub Actions Inactive
@lawmicha lawmicha temporarily deployed to IntegrationTest February 1, 2023 21:11 — with GitHub Actions Inactive
@lawmicha lawmicha temporarily deployed to IntegrationTest February 1, 2023 21:12 — with GitHub Actions Inactive
@lawmicha lawmicha temporarily deployed to IntegrationTest February 3, 2023 20:48 — with GitHub Actions Inactive
@lawmicha lawmicha temporarily deployed to IntegrationTest February 3, 2023 20:49 — with GitHub Actions Inactive
@lawmicha lawmicha marked this pull request as ready for review February 7, 2023 21:56
@lawmicha lawmicha temporarily deployed to IntegrationTest February 8, 2023 00:03 — with GitHub Actions Inactive
@lawmicha lawmicha temporarily deployed to IntegrationTest February 8, 2023 00:03 — with GitHub Actions Inactive
royjit
royjit previously approved these changes Feb 8, 2023
Copy link
Contributor

@royjit royjit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving, since all underlying PRs are approved and tested against integration test/

lawmicha and others added 11 commits February 7, 2023 19:40
* adds selection set customization to api category

* fix selection set indent logic

* lazy load all commits

* Add PrimaryKeyOnly flag to GraphQLRequestBuilders

* API - Add initial PostComment4V2 tests

* API progress on PostComment4V2 tests

* API update and delete tests for PostComment4V2 tests

* cancel subscription in subscription tests

* Adding copy of DataStore tests and make buildable

* updated codegen for postcomment and minor testSave tests

* Setting up ProjectTeam codegen schemas and running initial test

* API LL3 LL4 testing

* API LL5 LL6 testing

* API LL2 testing

* disable unfinished tests

* Update DataStore integ models with modePath

* fix unit tests in API and DataStore

* test DS integration tests

* migrate LazyModel to LazyReference

* code clean up

* code clean up

* Update Amplify-Package.xcscheme

* add geo scheme

* code clean up

* address PR comments 1 - remove duplicate state enum, move primaryKeysOnly check within decorator

* fix primaryKey parameter

* add L12 codegenerated files

* API testing LL12

* DS LL12 test placeholder

* enable reduced selection set for DataStore for all operations

* disable reduced selection set for DataStore mutations

* disable reduced selection set for DataStore mutations 2

* remove print statments

* add typename from client side for DataStore MutationSync<AnyModel>

* add _deleted to new subscription selection sets only for nested children, more API CommentPost schema integ tests, fix AWSPluginsCore unit tests

* fix API integ tests for ProjectTeam 5/6

* optimize list and lazy reference decoding logic

* remove public loadingStrategy configuration

* fix race case for plugin resets wrt the ModelRegistry being reset

* update models and fix tests

* test stability - set up datastore only for selection set tests

* reduce logging in Decorator

* test stability - reduce syncMaxRecords to 100

* test stability - clearOnTearDown false for all tests

* API integ tests - subscribe team project LL8/9

* API integ tests - refactor LL112 into 3 separate test classes

* PhoneCall testing

* fix error handling
- remove DataError
- return API or DataStore error from respective plugin model providers
- return CoreError from core implementation

* code clean up
- rename shouldDecode to decode
- use _ prefix for public but intended internal

Co-authored-by: Daniel Rochetti <[email protected]>
…ly (#2684)

* chore: enable lazy loading integration tests

* fix(datastore): observe API mutation event decode to model successfully

* update branches for GH workflows

* fix typo
* fix(datastore): covert with schema fields

* fix: remove redundant code

* fix: mark empty record with nil

* fix: graphQL payload generate order

* fix: recursive function break condition
* chore: enable lazy loading integration tests

* update branches for GH workflows

* fix: test UserPostComment schema

* add lazy load tests

* add schema with Double field, fix PropertyPath
…ion (#2701)

* testing DataStore HasOneParentChild

* add more testing

* Add list query API integ tests

* remove config comment

* Add DS lazy load observeQuery tests

* add API include nested models

* fix: do not set nil values for create mutation graphQL input translation

* fix hasOneParent test

* fix DataStore LL5 testSaveProjectWithTeamThenAccessProjectFromTeam
* fix: uni-directional has-many lazy list load

* remove redundant log

* rename targetNames to use associatedWithFields

* rename associatedWithFields to associatedFields
…te key (#2737)

* fix(datastore): load has-one reference with composite key

* fix: update descretKeys split logic

* fix: add associatedFields for hashOne and belongsTo

* fix: change json object seralization
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants