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

Update amazonka #3

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Conversation

MichaelXavier
Copy link
Collaborator

This MR updates the repo to be compatible with the current develop branch of amazonka. Amazonka has not been getting releases to hackage with any kind of regularity so at my job we've moved to tracking the develop branch. Because your project is released to hackage you might decide that you only want to target the hackage 1.6.1 version which was released in February 2019, in which case feel free to close this MR or keep it open until amazonka gets a release.

There's a lot of diff here but here's a summary of the changes to amazonka off the top of my head:

  • amazonka-core is gone
  • MonadAWS/RunAWS are gone. Instead, send takes the env value directly. So your APIs that hit AWS now take an additional argument.
  • All constructors are prefixed with new, e.g. putItem becomes newPutItem
  • All field lenses now live in a dedicated lens module and are prefixed with the full type (e.g. putItem_) instead of a cryptic abbreviation.
  • Most sum types are now actually a newtype over Text and what were previously sum type constructors are view patterns. I had to add a custom sum type ScalarValueType for the GADT ScalarValue because you can't use view patterns as type parameters for GADTs. The functionality should be equivalent though.
  • Most fields in requests/response that are of type [a] are now Maybe [a]. So you'll see a lot of fromMaybe mempty that smooths over this.

I also added stack files to make it a bit easier to test reproducibly but feel free to remove that.

I've merged this branch into a large project that uses dynamodb-simple and so far everything seems to be working.

@ondrap
Copy link
Owner

ondrap commented Sep 30, 2021

Wow. I don't follow the dev cycle of amazonka, but I have a few projects that use that; that's going to be fun :( I think I'd probably keep it open, until amazonka is released on hackage. Could you ping me when this happens?

To be honest, I don't use this library anymore, I switched the app to sql.. any interest into becoming a maintainer? :)

@MichaelXavier
Copy link
Collaborator Author

I don't think I can in good conscience agree to becoming sole maintainer, but since my work uses this library I'd be okay with being a co-maintainer. Seems like there isn't much issue volume with the library, so that's good!

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