Skip to content
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

Feature request: configuration field to call a transform function #76

Open
StevenH86 opened this issue Apr 24, 2024 · 1 comment
Open

Comments

@StevenH86
Copy link

Hey team, I'm in the process of migrating from Algolia to typesense and all is going well, however, the Algolia extension allows us to provide the name of a another function that can transform our document data before writing it to the Algolia index.

This would be extremely useful to have available in the typesense extension. We use it to modify one of the ID's as we are indexing a subcollection that exists nested in multiple places e.g. programs/{programId}/program-users/{userId}. As the docs we are indexing are keyed by the userId we need to append the programId as a suffix to prevent records overwriting each other.

I believe something like a transform function would be useful for a bunch of other lodged issues where people want to exclude records with certain values from their typesense collection. Supporting a returned object like below would be extremely useful.

{ payload: { ... data to sync }, docId: 'someId', action: 'skip' // 'skip' | 'sync' | 'delete' }

This would allow us to have more control over what goes into our typesense collections.

Cheers

@jasonbosco
Copy link
Member

I'd definitely appreciate a PR for this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants