-
Notifications
You must be signed in to change notification settings - Fork 104
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
Migrate support
module to Server Preset (Part 5)
#4956
Conversation
|
@@ -1,7 +1,7 @@ | |||
/* This file was automatically generated. DO NOT UPDATE MANUALLY. */ | |||
import type { Resolvers } from './../../__generated__/types.next'; | |||
import { Organization } from './resolvers/Organization'; | |||
import { Organization as rate_limit_Organization } from './resolvers/Organization'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This rename is expected because other modules are extending type Organization
, so server preset adds module name to distinguish them, even if they are not all in one file
🐋 This PR was built and pushed to the following Docker images (tag: Docker Bake metadata{
"app": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/tu9agj4et2y1sqyy9uwqx6mgn",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:7dbfc399edb0fc2b4c132068b7f9f615b181b12b9555679590fe8a230093bad2",
"size": 685
},
"containerimage.digest": "sha256:7dbfc399edb0fc2b4c132068b7f9f615b181b12b9555679590fe8a230093bad2",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/app:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/app:migrate_modules_5"
},
"composition-federation-2": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/nblfrnjhxskljo3huxb7tqcxb",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:b09858f6a382bed61c93c827eb7c7c8299b4edc3bb2de1c9b74a1eac3a74bcb6",
"size": 685
},
"containerimage.digest": "sha256:b09858f6a382bed61c93c827eb7c7c8299b4edc3bb2de1c9b74a1eac3a74bcb6",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/composition-federation-2:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/composition-federation-2:migrate_modules_5"
},
"emails": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/vgevn6vm7f916t4h4ek3xyvy2",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:4cf50853bf6522af600ba7765253b62241d642034792e8eb1b13e40ae07e345b",
"size": 685
},
"containerimage.digest": "sha256:4cf50853bf6522af600ba7765253b62241d642034792e8eb1b13e40ae07e345b",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/emails:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/emails:migrate_modules_5"
},
"policy": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/pddpytc0yr12xyw6td69tfxw0",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:5be4c1971f0258ce7496908d7570f58aa7a15854c1716ba457341ec711e0daa2",
"size": 685
},
"containerimage.digest": "sha256:5be4c1971f0258ce7496908d7570f58aa7a15854c1716ba457341ec711e0daa2",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/policy:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/policy:migrate_modules_5"
},
"rate-limit": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/0p3gevcwnalncdkx0io3kfvms",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:41c01be3abadc407e33bcc9d317388c7a6e66c7b7eaf9d267b0d0f1ced3d105e",
"size": 685
},
"containerimage.digest": "sha256:41c01be3abadc407e33bcc9d317388c7a6e66c7b7eaf9d267b0d0f1ced3d105e",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/rate-limit:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/rate-limit:migrate_modules_5"
},
"schema": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/3nejvbqbws8nmp80o91rcskli",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:708bf661144450f6bc1197a64755dd65e68f9691e509e636dc9fd01f728b5488",
"size": 685
},
"containerimage.digest": "sha256:708bf661144450f6bc1197a64755dd65e68f9691e509e636dc9fd01f728b5488",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/schema:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/schema:migrate_modules_5"
},
"server": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/f9539ue3z1vmwznsw9ugy2wjz",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:906cbc1093e0f98bdf5f36a64094be4b1fd5bd8d78c521a67335932542a8f846",
"size": 685
},
"containerimage.digest": "sha256:906cbc1093e0f98bdf5f36a64094be4b1fd5bd8d78c521a67335932542a8f846",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/server:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/server:migrate_modules_5"
},
"storage": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/zeddotbghkm9fdo5qcjzgeor5",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:25d0f06efd73fb3bd3da847faf0e97c7dd2aba3ee1e45fe10f5de0e0b40f825f",
"size": 685
},
"containerimage.digest": "sha256:25d0f06efd73fb3bd3da847faf0e97c7dd2aba3ee1e45fe10f5de0e0b40f825f",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/storage:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/storage:migrate_modules_5"
},
"stripe-billing": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/ccwhzv95tsomrykhjjbs9wfto",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:7128029204124205e66b40a9ceda21508adf0f5334ad728b0ed0c59e97dc254a",
"size": 685
},
"containerimage.digest": "sha256:7128029204124205e66b40a9ceda21508adf0f5334ad728b0ed0c59e97dc254a",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/stripe-billing:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/stripe-billing:migrate_modules_5"
},
"tokens": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/6ur54dmtlmzpq63qi4q8plfw2",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:8cdaa6a34f0b42b5513663914c378a52d3f42769607fd9f9ca7fa5911f087820",
"size": 685
},
"containerimage.digest": "sha256:8cdaa6a34f0b42b5513663914c378a52d3f42769607fd9f9ca7fa5911f087820",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/tokens:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/tokens:migrate_modules_5"
},
"usage": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/bwkq3xkc9nib0vnkqn9raubhw",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:ef7ec677f5a42ddb02081f466fbdb99099d91c9d18b559e3ad6fc815890bcef5",
"size": 685
},
"containerimage.digest": "sha256:ef7ec677f5a42ddb02081f466fbdb99099d91c9d18b559e3ad6fc815890bcef5",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/usage:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/usage:migrate_modules_5"
},
"usage-estimator": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/0e60xf8unku3omjdlqdxanq2n",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:c91e748d6ab1c207cca855e2c4516cfcad018a38cc0ea435509dc5b9bd9f7a08",
"size": 685
},
"containerimage.digest": "sha256:c91e748d6ab1c207cca855e2c4516cfcad018a38cc0ea435509dc5b9bd9f7a08",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/usage-estimator:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/usage-estimator:migrate_modules_5"
},
"usage-ingestor": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/ek204bzkw6p9fancojytt69aw",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:d90be8679e8e72b178e92cc21ff10f1ba218e005747d751f88b268ed53a8f0a4",
"size": 685
},
"containerimage.digest": "sha256:d90be8679e8e72b178e92cc21ff10f1ba218e005747d751f88b268ed53a8f0a4",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/usage-ingestor:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/usage-ingestor:migrate_modules_5"
},
"webhooks": {
"buildx.build.ref": "builder-a78cab8b-886d-4cc7-be56-198e17f59ce6/builder-a78cab8b-886d-4cc7-be56-198e17f59ce60/r86rm0ajjz0rzjpk3ysty06ay",
"containerimage.descriptor": {
"mediaType": "application/vnd.docker.distribution.manifest.list.v2+json",
"digest": "sha256:71753bf63cb69189e51d70453964ff39fc5d120527eb813c1b5bdff9e1e1ae11",
"size": 685
},
"containerimage.digest": "sha256:71753bf63cb69189e51d70453964ff39fc5d120527eb813c1b5bdff9e1e1ae11",
"image.name": "ghcr.io/kamilkisiela/graphql-hive/webhooks:73056eb3b324c0f2ef8018485341dd12f435d10e,ghcr.io/kamilkisiela/graphql-hive/webhooks:migrate_modules_5"
}
} |
comments: async (ticket, _args, { injector }) => { | ||
const response = await injector.get(SupportManager).getTicketComments(ticket.id); | ||
|
||
return { | ||
edges: response.nodes.map(comment => ({ | ||
node: { | ||
id: String(comment.id), | ||
body: comment.body, | ||
createdAt: comment.created_at, | ||
fromSupport: comment.fromSupport, | ||
}, | ||
cursor: String(comment.id), | ||
})), | ||
pageInfo: { | ||
endCursor: String(response.nodes[response.nodes.length - 1]?.id ?? ''), | ||
hasNextPage: response.meta.has_more, | ||
hasPreviousPage: false, | ||
startCursor: String(response.nodes[0]?.id ?? ''), | ||
}, | ||
}; | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The schema for this type is this:
comments: SupportTicketCommentConnection
This seems a bit different from other *Connection
as they are usually non-nullable i.e. *Connection!
.
Looking at the implementation, it can never be null. So I think this could be a way to get around having to declare mapper for SupportTicket
? 🤔
Either way, this is part of the migration so we should keep the implementation as-is, however, I think we should change the type to SupportTicketCommentConnection!
so it correctly reflects the logic.
Unless I misunderstood it, then please let me know!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kamilkisiela Did you think about anything specific when u implemented this?
3cd67cf
to
56b94fd
Compare
1342738
to
8498bc9
Compare
054dd7b
to
6b00207
Compare
- Migrate Mutation.supportTicketCreate - Migrate Mutation.supportTicketReply - Migrate Organization.supportTickets and Organization.supportTickets - Migrate SupportTicket - Migrate SupportTicketPriority and SupportTicketStatus
6b00207
to
73056eb
Compare
Background
This PR migrates
support
module to Server PresetTODO
shared
module to Server Preset (Part 4) #4955