Skip to content

Conversation

christophgysin
Copy link
Contributor

Commit Message

feat: Support AppSync DataSource type: NONE

End Commit Message


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

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject6AEA49D1-qxepHUsryhcu
  • Commit ID: 77e7f3c
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

/**
* Properties for an AppSync dummy datasource
*/
export interface NoneDataSourceProps extends BaseDataSourceProps {
Copy link
Contributor

Choose a reason for hiding this comment

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

@eladb whats your opinion on extending just for renaming like this? Is it appropriate for NoneDateSource to just accept BaseDataSourceProps?

Copy link
Contributor

Choose a reason for hiding this comment

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

Ideally this datasource wouldn't allow you to set serviceRole at all.

My hacky workaround to this in #6836 (comment) was to do:

export interface NoneDataSourceProps extends BaseDataSourceProps {
  readonly serviceRole?: undefined
}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

One way to implement this would be to remove serviceRole from BaseDataSourceProps, and instead add it to a new BackedDataSourceProps interface that others can inherit from.

Copy link
Contributor

Choose a reason for hiding this comment

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

This seems like something we should do sooner or later. @christophgysin you okay with implementing that here?

Copy link
Contributor Author

@christophgysin christophgysin Apr 11, 2020

Choose a reason for hiding this comment

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

Sure, will try to do this early next week.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have extracted serviceRole to BackedDataSourceProps. Please have a look at 154390d

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The question still remains if NoneDateSourceProps should exist at all, or if NoneDateSource should just accept BaseDataSourceProps?

Copy link
Contributor

Choose a reason for hiding this comment

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

Let's keep NoneDataSourceProps for now.

@0xdevalias 0xdevalias mentioned this pull request Apr 8, 2020
20 tasks
@christophgysin christophgysin force-pushed the appsync-datasource-none branch from 77e7f3c to 01f0670 Compare April 14, 2020 07:06
@christophgysin christophgysin force-pushed the appsync-datasource-none branch from 01f0670 to ffdba44 Compare April 14, 2020 07:08
@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject6AEA49D1-qxepHUsryhcu
  • Commit ID: 01f0670
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject6AEA49D1-qxepHUsryhcu
  • Commit ID: ffdba44
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify
Copy link
Contributor

mergify bot commented Apr 14, 2020

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject6AEA49D1-qxepHUsryhcu
  • Commit ID: 664566a
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify
Copy link
Contributor

mergify bot commented Apr 14, 2020

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify mergify bot merged commit f35a4db into aws:master Apr 14, 2020
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.

4 participants