Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add serde support to document type. #2616

Conversation

thomas-k-cameron
Copy link
Contributor

@thomas-k-cameron thomas-k-cameron commented Apr 21, 2023

Description

Implements serde support for Document.

Testing

Test checks whether the serialized/de-serialized data matches with the expected value


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@thomas-k-cameron thomas-k-cameron changed the title Rfc30/rust runtime impl serde on runtime types Implement serde support to smithy types Apr 26, 2023
@thomas-k-cameron thomas-k-cameron mentioned this pull request Apr 26, 2023
2 tasks
@thomas-k-cameron thomas-k-cameron marked this pull request as ready for review April 26, 2023 11:46
@thomas-k-cameron thomas-k-cameron requested review from a team as code owners April 26, 2023 11:46
@thomas-k-cameron thomas-k-cameron marked this pull request as draft April 26, 2023 11:48
david-perez pushed a commit that referenced this pull request May 18, 2023
## Motivation and Context
This PR refactors `aws-smithy-types` crate. 
`Blob`, `Datetime`, `Number` and `Document` structs now goes to it's own
files.
No changes on feature is introduced.

This is a child-PR of #2616 .
However, it is completely independent.

PR that introduces same changes were previously merged to
`unstable-serde` branch, however, it has not been merged to main branch.

## Testing
NA

## Checklist
This PR does not introduce API changes.
----

_By submitting this pull request, I confirm that you can use, modify,
copy, and redistribute this contribution, under the terms of your
choice._
david-perez pushed a commit that referenced this pull request May 22, 2023
## Motivation and Context
This PR refactors `aws-smithy-types` crate. 
`Blob`, `Datetime`, `Number` and `Document` structs now goes to it's own
files.
No changes on feature is introduced.

This is a child-PR of #2616 .
However, it is completely independent.

PR that introduces same changes were previously merged to
`unstable-serde` branch, however, it has not been merged to main branch.

## Testing
NA

## Checklist
This PR does not introduce API changes.
----

_By submitting this pull request, I confirm that you can use, modify,
copy, and redistribute this contribution, under the terms of your
choice._
david-perez pushed a commit that referenced this pull request May 22, 2023
## Motivation and Context
This PR refactors `aws-smithy-types` crate. 
`Blob`, `Datetime`, `Number` and `Document` structs now goes to it's own
files.
No changes on feature is introduced.

This is a child-PR of #2616 .
However, it is completely independent.

PR that introduces same changes were previously merged to
`unstable-serde` branch, however, it has not been merged to main branch.

## Testing
NA

## Checklist
This PR does not introduce API changes.
----

_By submitting this pull request, I confirm that you can use, modify,
copy, and redistribute this contribution, under the terms of your
choice._
aws-sdk-rust-ci pushed a commit to awslabs/aws-sdk-rust that referenced this pull request May 24, 2023
## Motivation and Context
This PR refactors `aws-smithy-types` crate.
`Blob`, `Datetime`, `Number` and `Document` structs now goes to it's own
files.
No changes on feature is introduced.

This is a child-PR of smithy-lang/smithy-rs#2616 .
However, it is completely independent.

PR that introduces same changes were previously merged to
`unstable-serde` branch, however, it has not been merged to main branch.

## Testing
NA

## Checklist
This PR does not introduce API changes.
----

_By submitting this pull request, I confirm that you can use, modify,
copy, and redistribute this contribution, under the terms of your
choice._
jdisanti added a commit that referenced this pull request May 30, 2023
## Motivation and Context
This is a child PR of #2616

The changes that this PR introduces is same as the ones that were merged
to `unstable-serde-support` branch before.

Initially, we tried to make commit to unstable-serde-support branch and
merge changes one by one in small PRs. However, in order to make it up
to date with the main branch, we would need to go through a large PR of
over 700 files.

Thus, I decided to create individual PRs that commits directly to `main`
branch.

## Description
- Implements `serde` support to `Number`

## Testing
- Test checks whether the serialized/de-serialized data matches with the
expected value

## Checklist
NA

----

_By submitting this pull request, I confirm that you can use, modify,
copy, and redistribute this contribution, under the terms of your
choice._

---------

Co-authored-by: John DiSanti <[email protected]>
Co-authored-by: John DiSanti <[email protected]>
jdisanti pushed a commit that referenced this pull request Jun 5, 2023
## Motivation and Context
This is a child PR of #2616

The changes that this PR introduces is same as the ones that were merged
to `unstable-serde-support` branch before.

Initially, we tried to make commit to unstable-serde-support branch and
merge changes one by one in small PRs. However, in order to make it up
to date with the main branch, we would need to go through a large PR of
over 700 files.

Thus, I decided to create individual PRs that commits directly to `main`
branch.

## Description
- Implements `serde` support to `DateTime`

## Testing
- Test checks whether the serialized/de-serialized data matches with the
expected value

## Checklist
NA

----

_By submitting this pull request, I confirm that you can use, modify,
copy, and redistribute this contribution, under the terms of your
choice._
jdisanti added a commit that referenced this pull request Jun 6, 2023
## Motivation and Context
This is a child PR of #2616

The changes that this PR introduces is same as the ones that were merged
to `unstable-serde-support` branch before.

Initially, we tried to make commit to unstable-serde-support branch and
merge changes one by one in small PRs. However, in order to make it up
to date with the main branch, we would need to go through a large PR of
over 700 files.

Thus, I decided to create individual PRs that commits directly to `main`
branch.

## Description
- Implements `serde` support to `Blob`

## Testing
- Test checks whether the serialized/de-serialized data matches with the
expected value

## Checklist
NA

----

_By submitting this pull request, I confirm that you can use, modify,
copy, and redistribute this contribution, under the terms of your
choice._

---------

Co-authored-by: John DiSanti <[email protected]>
@jdisanti
Copy link
Collaborator

It looks like after the smaller prerequisite PRs are merged, the only functionality that still needs to be added is ser/de support for Document. Is that correct? If so, could you either repurpose this PR by updating the description/title, or create a new one just for Document?

@thomas-k-cameron thomas-k-cameron changed the title Implement serde support to smithy types Add serde support to document type. Jun 13, 2023
@thomas-k-cameron
Copy link
Contributor Author

It looks like after the smaller prerequisite PRs are merged, the only functionality that still needs to be added is ser/de support for Document. Is that correct? If so, could you either repurpose this PR by updating the description/title, or create a new one just for Document?

Yes, document type is the only thing that is left.

I changed the title.

Copy link
Collaborator

@jdisanti jdisanti left a comment

Choose a reason for hiding this comment

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

Looks good. Thank you!

feature = "serde-serialize",
feature = "serde-deserialize"
))]
fn serialize_json() {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nice test!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

:D

@jdisanti jdisanti enabled auto-merge June 14, 2023 17:00
@jdisanti jdisanti added this pull request to the merge queue Jun 14, 2023
Merged via the queue into smithy-lang:main with commit 9d56db1 Jun 14, 2023
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.

2 participants