Skip to content

Commit

Permalink
enh(tracker): reduce gdrive debounce and run upsert hooks in dev (#9500)
Browse files Browse the repository at this point in the history
Co-authored-by: Henry Fontanier <henry@dust.tt>
  • Loading branch information
fontanierh and Henry Fontanier authored Dec 18, 2024
1 parent 3934fca commit af7d8f7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion front/lib/document_upsert_hooks/hooks/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import type { ConnectorProvider, UpsertContext } from "@dust-tt/types";
import { isDevelopment } from "@dust-tt/types";

import type { Authenticator } from "@app/lib/auth";
import { trackerUpsertHook } from "@app/lib/document_upsert_hooks/hooks/tracker";
Expand Down Expand Up @@ -30,7 +31,7 @@ export function runDocumentUpsertHooks(
params: Parameters<DocumentUpsertHook["fn"]>[0]
): void {
// TODO(document-tracker): remove this once we have a way to enable/disable
if (params.auth.workspace()?.sId !== DUST_WORKSPACE) {
if (params.auth.workspace()?.sId !== DUST_WORKSPACE && !isDevelopment()) {
return;
}

Expand Down
2 changes: 1 addition & 1 deletion front/temporal/tracker/workflows.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export async function trackersGenerationWorkflow(
if (!dataSourceConnectorProvider) {
return 10000;
}
if (dataSourceConnectorProvider === "notion") {
if (["notion", "google_drive"].includes(dataSourceConnectorProvider)) {
return 600000;
}
return 3600000;
Expand Down

0 comments on commit af7d8f7

Please sign in to comment.