Skip to content
This repository has been archived by the owner on Mar 10, 2024. It is now read-only.

feat: sync standard objects for gong #1233

Merged
merged 2 commits into from
Jul 14, 2023
Merged

feat: sync standard objects for gong #1233

merged 2 commits into from
Jul 14, 2023

Conversation

albertyfwu
Copy link
Contributor

@albertyfwu albertyfwu commented Jul 13, 2023

Supports syncing standard objects for Gong.

Caveats:

  • even if a field mapping is set, it's ignored
  • haven't tested real rate limiting (429), because I didn't run into it while testing; we can artificially try to hit 429 if we want

Test Plan

[Describe test plan here]

Deployment instructions

[Add any special deployment instructions here]

@vercel
Copy link

vercel bot commented Jul 13, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Ignored Deployments
Name Status Preview Comments Updated (UTC)
management-ui ⬜️ Ignored (Inspect) Visit Preview Jul 13, 2023 8:09pm
supaglue-docs ⬜️ Ignored (Inspect) Visit Preview Jul 13, 2023 8:09pm

data: toSyncConfigModel(syncConfig),
});

await tx.syncConfigChange.create({
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this is a bug where we weren't creating ObjectSyncs when SyncConfig was updated with new objects.

create: toSyncConfigModel(syncConfig),
update: toSyncConfigModel(syncConfig),

const upsertedSyncConfigModel = await this.#prisma.$transaction(async (tx) => {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

another bug

await this.#prisma.syncConfig.deleteMany({
where: { id, applicationId },
});
await this.#prisma.$transaction([
Copy link
Contributor Author

Choose a reason for hiding this comment

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

another bug

@tomkit
Copy link
Contributor

tomkit commented Jul 14, 2023

some thoughts:

  • can we verify the user wants to consume these as three separate tables?
  • can we validate ui and api input to only accept the known enums and/or provide a select option in the mgmt-ui the way we do for salesforce
  • thoughts on just using lowercased names? hubspot is lower case, salesforce is pascal. we don't need to add camelCasing if it's our own choosing

@albertyfwu albertyfwu merged commit 8d67679 into main Jul 14, 2023
10 checks passed
@albertyfwu albertyfwu deleted the albert/gong branch July 14, 2023 16:39
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants