awslabs / aws-mobile-appsync-sdk-android

Android SDK for AWS AppSync.
https://docs.amplify.aws/sdk/api/graphql/q/platform/android/
Apache License 2.0
105 stars 58 forks source link

Decouple Apollo related code from jar #239

Closed darylsze closed 4 years ago

darylsze commented 4 years ago

Problem faced:

I would like to plug latest apollo client into project with appsync sdk. However, appsync sdk includes whole apollo related project folder, but not a gradle dependency, so that I cannot simply exclude from gradle exclude group:"com.apollographql.apollo".

Proposed Solution

Remove com.apollographql.apollo package from sdk, and add gradle dependency com.apollographql.apollo:apollo-runtime:x.y.z

raphkim commented 4 years ago

Hi @darylsze,

Thanks for reaching out. Our AppSync SDK does reuse much of code from Apollo, but we have made several changes in the codebase along the way to accommodate our purposes. This makes our internal Apollo package difficult to replace.

@undefobj, would you be able to confirm that this is the case and elaborate on potential action item?

undefobj commented 4 years ago

@darylsze at the time of original release there was not a comprehensive link implementation in Apollo Android or iOS like there is for JavaScript. We spoke with the Apollo team about this and the timelines didn't match up for us to jointly work on a solution based on customer demand. Apollo has evolved since then, and we are working on Amplify GA release which has an alternative GraphQL client, so we should be able to do this sometime in the future. I do not have a timeline however and it is more than likely 6+ months or longer out.