Skip to content

Commit f890e34

Browse files
authored
Change "Apollo Android" to "Apollo Kotlin" in code and internal docs (#3668)
1 parent 2b67dd3 commit f890e34

File tree

16 files changed

+40
-40
lines changed

16 files changed

+40
-40
lines changed

CONTRIBUTING.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Contributing to Apollo Android
1+
# Contributing to Apollo Kotlin
22

33
The Apollo team welcomes contributions of all kinds, including bug reports, documentation, test cases, bug fixes, and
44
features.
@@ -62,7 +62,7 @@ Java interop
6262
* If some extensions do not make sense in Java, mark them with `@JvmName("-$methodName")` to hide them from Java
6363

6464
Logging & Error messages
65-
* Apollo Android must not log anything to System.out or System.err
65+
* Apollo Kotlin must not log anything to System.out or System.err
6666
* Error messages are passed to the user through `Exception.message`
6767
* For debugging logs, APIs are provided to get diagnostics (like CacheMissException, HttpInfo, ...). APIs are better defined and allow more fine-grained diagnostics.
6868
* There is one exception for the Gradle plugin. It is allowed to log information though the lifecycle() methods.
@@ -84,7 +84,7 @@ Please note that we will not accept pull requests for style changes.
8484

8585
## API compatibility
8686

87-
Apollo Android observes [semantic versioning](https://semver.org/). Between major releases, breaking changes are not
87+
Apollo Kotlin observes [semantic versioning](https://semver.org/). Between major releases, breaking changes are not
8888
allowed and any public API change will fail the build.
8989

9090
If that happens, you will need to run `./gradlew apiDump` and check for any incompatible changes before commiting these
@@ -94,7 +94,7 @@ files.
9494

9595
Using Kotlin's (or other dependencies') experimental or internal APIs, such as the ones marked
9696
with `@ExperimentalCoroutinesApi` should be avoided as much as possible (exceptions can be made for native/JS targets only when no other option is
97-
available). Indeed, applications using a certain version of Apollo Android could use a more up-to-date version of these
97+
available). Indeed, applications using a certain version of Apollo Kotlin could use a more up-to-date version of these
9898
APIs than the one used when building the library, causing crashes or other issues.
9999

100100
We also have the `@ApolloExperimental` annotation which can be used to mark APIs as experimental, for instance when

README.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11

2-
# Apollo Android
2+
# Apollo Kotlin
33

44
[![GitHub license](https://img.shields.io/badge/license-MIT-lightgrey.svg?maxAge=2592000)](https://raw.githubusercontent.com/apollographql/apollo-android/main/LICENSE)
55
[![Join the community](https://img.shields.io/discourse/status?label=Join%20the%20community&server=https%3A%2F%2Fcommunity.apollographql.com)](http://community.apollographql.com/new-topic?category=Help&tags=mobile,client)
@@ -8,9 +8,9 @@
88
[![Maven Central](https://img.shields.io/maven-central/v/com.apollographql.apollo3/apollo-api)](https://repo1.maven.org/maven2/com/apollographql/apollo3/)
99
[![OSS Snapshots](https://img.shields.io/nexus/s/com.apollographql.apollo3/apollo-api?server=https%3A%2F%2Foss.sonatype.org&label=oss-snapshots)](https://oss.sonatype.org/content/repositories/snapshots/com/apollographql/apollo3/)
1010

11-
Apollo Android is a GraphQL client that generates Kotlin and Java models from GraphQL queries.
11+
Apollo Kotlin is a GraphQL client that generates Kotlin and Java models from GraphQL queries.
1212

13-
Apollo Android executes queries and mutations against a GraphQL server and returns results as query-specific Kotlin types. This means you don't have to deal with parsing JSON, or passing around `Map`s and making clients cast values to the right type manually. You also don't have to write model types yourself, because these are generated from the GraphQL definitions your UI uses.
13+
Apollo Kotlin executes queries and mutations against a GraphQL server and returns results as query-specific Kotlin types. This means you don't have to deal with parsing JSON, or passing around `Map`s and making clients cast values to the right type manually. You also don't have to write model types yourself, because these are generated from the GraphQL definitions your UI uses.
1414

1515
Because generated types are query-specific, you can only access data that you actually specify as part of a query. If you don't ask for a particular field in a query, you can't access the corresponding property on the returned data structure.
1616

@@ -34,7 +34,7 @@ This library is designed primarily with Android in mind, but you can use it in a
3434

3535
## Multiplatform
3636

37-
Apollo Android is a [Kotlin Multiplatform](https://kotlinlang.org/docs/multiplatform.html) project.
37+
Apollo Kotlin is a [Kotlin Multiplatform](https://kotlinlang.org/docs/multiplatform.html) project.
3838

3939
Here's the current matrix of supported features per platform:
4040

@@ -70,7 +70,7 @@ Check [the project website](https://www.apollographql.com/docs/android/) for in
7070

7171
If you are new to GraphQL, check out [the tutorial](https://www.apollographql.com/docs/android/v3/tutorial/00-introduction/) that will guide you through building an Android app using Apollo, Kotlin and coroutines.
7272

73-
If you'd like to add Apollo Android to an existing project, follow these steps:
73+
If you'd like to add Apollo Kotlin to an existing project, follow these steps:
7474

7575
Add the plugin to your `build.gradle.kts`:
7676

@@ -96,12 +96,12 @@ apollo {
9696
}
9797
```
9898

99-
Apollo Android supports three types of files:
99+
Apollo Kotlin supports three types of files:
100100
- `.graphqls` schema files: describes the types in your backend using the GraphQL syntax.
101101
- `.json` schema files: describes the types in your backend using the Json syntax.
102102
- `.graphql` executable files: describes your queries and operations in the GraphQL syntax.
103103

104-
By default, Apollo Android requires a schema in your module's `src/main/graphql` directory. You can download a schema using introspection with the `./gradlew downloadApolloSchema` task. Sometimes introspection is disabled and you will have to ask your backend team to provide a schema. Copy this schema to your module:
104+
By default, Apollo Kotlin requires a schema in your module's `src/main/graphql` directory. You can download a schema using introspection with the `./gradlew downloadApolloSchema` task. Sometimes introspection is disabled and you will have to ask your backend team to provide a schema. Copy this schema to your module:
105105

106106
```
107107
cp ${schema} ${module}/src/main/graphql/
@@ -133,7 +133,7 @@ Build your project, this will generate a `HeroQuery` class that you can use with
133133
println("Hero.name=${response.data?.hero?.name}")
134134
```
135135

136-
**To learn more about other Apollo Android APIs:**
136+
**To learn more about other Apollo Kotlin APIs:**
137137

138138
* Execute your first [mutation](https://www.apollographql.com/docs/android/v3/essentials/mutations/)
139139
* Handle [custom scalar types](https://www.apollographql.com/docs/android/v3/essentials/custom-scalars/)
@@ -204,9 +204,9 @@ If you'd like to contribute, please see [Contributing.md](https://github.com/apo
204204

205205
## Additional resources
206206

207-
- [MortyComposeKMM](https://github.com/joreilly/MortyComposeKMM): A Kotlin Multiplatform Github template using Apollo Android, SwiftUI and Jetpack Compose.
207+
- [MortyComposeKMM](https://github.com/joreilly/MortyComposeKMM): A Kotlin Multiplatform Github template using Apollo Kotlin, SwiftUI and Jetpack Compose.
208208
- [A journey to Kotlin multiplatform](https://www.youtube.com/watch?v=GN6LHrqyimI): how the project was moved to Kotlin multiplatform, talk given at Kotliners in June 2020.
209-
- [#125, Fragmented Podcast](http://fragmentedpodcast.com/episodes/125/): Why's and How's about Apollo Android and the entire journey.
209+
- [#125, Fragmented Podcast](http://fragmentedpodcast.com/episodes/125/): Why's and How's about Apollo Kotlin and the entire journey.
210210
- [GraphQL.org](http://graphql.org) for an introduction and reference to GraphQL itself.
211211
- [apollographql.com](http://www.apollographql.com/) to learn about Apollo open-source and commercial tools.
212212
- [The Apollo blog](https://www.apollographql.com/blog/) for long-form articles about GraphQL, feature announcements for Apollo, and guest articles from the community.
@@ -218,7 +218,7 @@ If you'd like to contribute, please see [Contributing.md](https://github.com/apo
218218

219219
* [Apollo Studio](https://www.apollographql.com/studio/develop/) – A free, end-to-end platform for managing your GraphQL lifecycle. Track your GraphQL schemas in a hosted registry to create a source of truth for everything in your graph. Studio provides an IDE (Apollo Explorer) so you can explore data, collaborate on queries, observe usage, and safely make schema changes.
220220
* [Apollo Federation](https://www.apollographql.com/apollo-federation) – The industry-standard open architecture for building a distributed graph. Use Apollo’s gateway to compose a unified graph from multiple subgraphs, determine a query plan, and route requests across your services.
221-
* [Apollo Client](https://www.apollographql.com/apollo-client/) – The most popular GraphQL client for the web. Apollo also builds and maintains [Apollo iOS](https://github.com/apollographql/apollo-ios) and [Apollo Android](https://github.com/apollographql/apollo-android).
221+
* [Apollo Client](https://www.apollographql.com/apollo-client/) – The most popular GraphQL client for the web. Apollo also builds and maintains [Apollo iOS](https://github.com/apollographql/apollo-ios) and [Apollo Kotlin](https://github.com/apollographql/apollo-android).
222222
* [Apollo Server](https://www.apollographql.com/docs/apollo-server/) – A production-ready JavaScript GraphQL server that connects to any microservice, API, or database. Compatible with all popular JavaScript frameworks and deployable in serverless environments.
223223

224224
## Learn how to build with Apollo

ROADMAP.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Roadmap
22

3-
This document is meant to give the community some idea of where we're going with Apollo Android in the short and longer term.
3+
This document is meant to give the community some idea of where we're going with Apollo Kotlin in the short and longer term.
44

5-
Please open issues or comment/upvote the existing ones for items you'd like to see added here. Feedback is very welcome! We'd love to learn more about how you're using Apollo Android and what you'd like to see in the future.
5+
Please open issues or comment/upvote the existing ones for items you'd like to see added here. Feedback is very welcome! We'd love to learn more about how you're using Apollo Kotlin and what you'd like to see in the future.
66

77
This document was last updated on October 25th, 2021.
88

@@ -24,9 +24,9 @@ As we move to a stable 3.0 release our priority will be to make sure the feedbac
2424

2525
The declarative cache makes working with the cache and defining unique object ids easier. We also want to include helpers to handle with common cases like pagination, garbage collection and eviction.
2626

27-
### Make Apollo Android even more multiplatform
27+
### Make Apollo Kotlin even more multiplatform
2828

29-
Apollo Android 3 is multiplatform first with runtime and cache support for the JVM, iOS, macOS and JS. We can do more to make the library even more easy to use:
29+
Apollo Kotlin 3 is multiplatform first with runtime and cache support for the JVM, iOS, macOS and JS. We can do more to make the library even more easy to use:
3030

3131
- HMPP support
3232
- Trying out and adopting the new memory model

apollo-ast/gradle.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
POM_ARTIFACT_ID=apollo-ast
2-
POM_NAME=Apollo Android Ast
3-
POM_DESCRIPTION=Apollo Android Ast
2+
POM_NAME=Apollo Kotlin Ast
3+
POM_DESCRIPTION=Apollo Kotlin Ast

apollo-ast/src/main/kotlin/com/apollographql/apollo3/ast/Issue.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ sealed class Issue(
4343
* Upper case fields are not supported as Kotlin doesn't allow a property name with the same name as a nested class.
4444
* If this happens, the easiest solution is to add an alias with a lower case first letter.
4545
*
46-
* This error is an Apollo Android specific error
46+
* This error is an Apollo Kotlin specific error
4747
*/
4848
class UpperCaseField(message: String, sourceLocation: SourceLocation) : Issue(message, sourceLocation, Severity.ERROR)
4949

@@ -80,4 +80,4 @@ enum class ValidationDetails {
8080
*/
8181
DuplicateTypeName,
8282
Other
83-
}
83+
}

apollo-ast/src/main/resources/apollo.graphqls

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Marks a field or variable definition as optional or required
2-
# By default Apollo Android generates all variables of nullable types as optional, in compliance with the GraphQL specification,
2+
# By default Apollo Kotlin generates all variables of nullable types as optional, in compliance with the GraphQL specification,
33
# but this can be configured with this directive, because if the variable was added in the first place, it's usually to pass a value
44
directive @optional(if: Boolean = true) on FIELD | VARIABLE_DEFINITION
55

apollo-compiler/gradle.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
POM_ARTIFACT_ID=apollo-compiler
2-
POM_NAME=Apollo Android Compiler
2+
POM_NAME=Apollo Kotlin Compiler
33
POM_DESCRIPTION=Implementation for the Gradle plugin
4-
POM_PACKAGING=jar
4+
POM_PACKAGING=jar

apollo-gradle-plugin/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ gradlePlugin {
9494
plugins {
9595
create("apolloGradlePlugin") {
9696
id = "com.apollographql.apollo3"
97-
displayName = "Apollo Android GraphQL client plugin."
97+
displayName = "Apollo Kotlin GraphQL client plugin."
9898
description = "Automatically generates typesafe java and kotlin models from your GraphQL files."
9999
implementationClass = "com.apollographql.apollo3.gradle.internal.ApolloPlugin"
100100
}

apollo-gradle-plugin/src/main/kotlin/com/apollographql/apollo3/gradle/api/Service.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ interface Service {
226226

227227
/**
228228
* A list of [Regex] patterns for input/scalar/enum types that should be generated whether they are used by queries/fragments
229-
* in this module. When using multiple modules, Apollo Android will generate all the types by default in the root module
229+
* in this module. When using multiple modules, Apollo Kotlin will generate all the types by default in the root module
230230
* because the root module doesn't know what types are going to be used by dependent modules. This can be prohibitive in terms
231231
* of compilation speed for large projects. If that's the case, opt-in the types that are used by multiple dependent modules here.
232232
* You don't need to add types that are used by a single dependent module.

apollo-gradle-plugin/src/main/kotlin/com/apollographql/apollo3/gradle/internal/KotlinPluginFacade.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ internal fun checkKotlinPluginVersion(project: Project) {
5555
else -> false
5656
}
5757
require(isKotlinSupported) {
58-
"Apollo Android requires Kotlin plugin version 1.4 or more (found '${project.getKotlinPluginVersion()}')"
58+
"Apollo Kotlin requires Kotlin plugin version 1.4 or more (found '${project.getKotlinPluginVersion()}')"
5959
}
6060
}
6161

apollo-gradle-plugin/src/test/kotlin/com/apollographql/apollo3/gradle/test/KotlinPluginVersionTests.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class KotlinPluginVersionTests {
2323
TestUtils.executeGradleWithVersion(dir, "5.6", "generateApolloSources")
2424
fail("An exception was expected")
2525
} catch (e: UnexpectedBuildFailure) {
26-
Truth.assertThat(e.message).contains("Apollo Android requires Kotlin plugin version 1.4")
26+
Truth.assertThat(e.message).contains("Apollo Kotlin requires Kotlin plugin version 1.4")
2727
}
2828
}
2929
}
@@ -37,4 +37,4 @@ class KotlinPluginVersionTests {
3737
Truth.assertThat(result.task(":help")!!.outcome).isEqualTo(TaskOutcome.SUCCESS)
3838
}
3939
}
40-
}
40+
}

design-docs/Codegen.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
# Codegen Models
22

3-
In order to provide type safety, Apollo Android generates Kotlin models from your queries. The fields you're querying will be accessible in the Kotlin models. Fields that are not queried will not be accessible. For simple queries, the mapping of GraphQL queries to Kotlin models is relatively natural. GraphQL objects are mapped to Kotlin data classes and GraphQL fields to Kotlin properties.
3+
In order to provide type safety, Apollo Kotlin generates Kotlin models from your queries. The fields you're querying will be accessible in the Kotlin models. Fields that are not queried will not be accessible. For simple queries, the mapping of GraphQL queries to Kotlin models is relatively natural. GraphQL objects are mapped to Kotlin data classes and GraphQL fields to Kotlin properties.
44

5-
For more complex queries, involving [merged fields](https://spec.graphql.org/draft/#sec-Field-Selection-Merging) and/or [fragments](https://spec.graphql.org/draft/#sec-Validation.Fragments) on different interfaces/union types, this mapping becomes more complicated as polymorphic types are needed. In order to accommodate different needs, Apollo Android supports three different codegen modes:
5+
For more complex queries, involving [merged fields](https://spec.graphql.org/draft/#sec-Field-Selection-Merging) and/or [fragments](https://spec.graphql.org/draft/#sec-Validation.Fragments) on different interfaces/union types, this mapping becomes more complicated as polymorphic types are needed. In order to accommodate different needs, Apollo Kotlin supports three different codegen modes:
66

77
* **responseBased**: the Kotlin models map the received json.
88
* **operationBased**: the Kotlin models map the sent operation.
9-
* **compat**: for compatibility with Apollo Android 2.x
9+
* **compat**: for compatibility with Apollo Kotlin 2.x
1010

1111
`operationBased` will generate less code but will use more memory and expose less type information. `responseBased` will generate interfaces to access the models in a more polymorphic way. It will also store each merged field exactly once and have more efficient json parsing. That comes at the price of more generated code.
1212

@@ -392,4 +392,4 @@ class Hero(
392392
)
393393
</pre></td>
394394
</tr>
395-
</table>
395+
</table>

design-docs/Json.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Json is a relatively simple format but there are a few caveats in Apollo Android:
1+
Json is a relatively simple format but there are a few caveats in Apollo Kotlin:
22

33
## Fields order
44

design-docs/Readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
## Design docs
22

3-
This is Apollo Android documentation for how things work under the hood. The user-facing documentation about how to use Apollo Android is available at https://www.apollographql.com/docs/android/.
3+
This is Apollo Kotlin documentation for how things work under the hood. The user-facing documentation about how to use Apollo Kotlin is available at https://www.apollographql.com/docs/android/.
44

55
This internal documentation is work in progress. It is used for brainstorming/communication but might be lagging sometimes, feel free to send PRs!

design-docs/Threading.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ class NativeSerialSharedState<T>(producer: () -> T): SharedState<T> {
155155
## Appendix-2 Non-goal: Atomic Cached Requests
156156

157157

158-
Apollo Android has no concept of "Atomic request". Launching the same request twice in a row will most likely end up in the request being sent to the network twice even if the first one will ultimately cache it (but this is not guaranteed either):
158+
Apollo Kotlin has no concept of "Atomic request". Launching the same request twice in a row will most likely end up in the request being sent to the network twice even if the first one will ultimately cache it (but this is not guaranteed either):
159159

160160
```kotlin
161161
val response1 = launch {

samples/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
If you're looking for a specific feature (APQs, Codegen options, `@nonnull`, ...) the [integration-tests](../tests) have a lot of very focused examples of how to use Apollo Android.
1+
If you're looking for a specific feature (APQs, Codegen options, `@nonnull`, ...) the [integration-tests](../tests) have a lot of very focused examples of how to use Apollo Kotlin.
22

33
For more general examples demonstrating how to build an App end to end, check:
44

55
* https://github.com/apollographql/apollo-android-tutorial for an **Android App** example
6-
* https://github.com/joreilly/MortyComposeKMM for a **Multiplatform App** example
6+
* https://github.com/joreilly/MortyComposeKMM for a **Multiplatform App** example

0 commit comments

Comments
 (0)