Skip to content

Commit

Permalink
fix(kw-search): snowflake tables should upsert w/ mimetype and title (#…
Browse files Browse the repository at this point in the history
…8977)

Co-authored-by: Henry Fontanier <[email protected]>
  • Loading branch information
fontanierh and Henry Fontanier authored Nov 27, 2024
1 parent adeb33c commit 6ccac3f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions connectors/src/connectors/snowflake/temporal/activities.ts
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,8 @@ export async function syncSnowflakeConnection(connectorId: ModelId) {
`${table.databaseName}.${table.schemaName}`,
table.databaseName,
],
title: table.name,
mimeType: "application/vnd.snowflake.table",
});
await table.update({
lastUpsertedAt: new Date(),
Expand Down
6 changes: 6 additions & 0 deletions connectors/src/lib/data_sources.ts
Original file line number Diff line number Diff line change
Expand Up @@ -566,6 +566,8 @@ export async function upsertTableFromConnectors({
remoteDatabaseSecretId,
loggerArgs,
parents,
title,
mimeType,
}: {
dataSourceConfig: DataSourceConfig;
tableId: string;
Expand All @@ -575,6 +577,8 @@ export async function upsertTableFromConnectors({
remoteDatabaseSecretId: string | null;
loggerArgs?: Record<string, string | number>;
parents: string[];
title: string;
mimeType: string;
}) {
const localLogger = logger.child({ ...loggerArgs, tableId, tableName });
const statsDTags = [
Expand All @@ -601,6 +605,8 @@ export async function upsertTableFromConnectors({
table_id: tableId,
remote_database_table_id: remoteDatabaseTableId,
remote_database_secret_id: remoteDatabaseSecretId,
title,
mimeType,
};
const dustRequestConfig: AxiosRequestConfig = {
headers: {
Expand Down

0 comments on commit 6ccac3f

Please sign in to comment.