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

Zyp Treatments: A slightly tailored transformation subsystem #46

Merged
merged 4 commits into from
Sep 10, 2024

Conversation

amotl
Copy link
Member

@amotl amotl commented Sep 7, 2024

About

Reading real-world data from MongoDB sometimes needs a few adjustments. Zyp Treatments propose to implement another possible variant to cope with them. They can be used independently of any runtime environment, and their concepts and ingredients can be tweaked based on new requirements as we go.

Details

Contrary to Zyp Transformations, rules of Zyp Treatments currently are not anchored to a certain node, for example using JSONPointer. Instead, they apply on all elements and levels of a document. Treatment rules are defined using Python code.

Usage

zyp-treatment-all.yaml is an example file representing a Zyp project that includes definitions of special treatments for a specific collection.

References

/cc @juanpardo, @wierdvanderhaar, @hlcianfagna, @lservini, @zolbatar

@amotl amotl changed the title Zyp: A miniature treatments subsystem Zyp Treatments: A slightly tailored transformation subsystem Sep 7, 2024
@amotl amotl marked this pull request as ready for review September 7, 2024 18:44
@amotl amotl force-pushed the zyp-treatments branch 2 times, most recently from 1859746 to 54bdb4d Compare September 7, 2024 23:15
Because CrateDB can not store lists of varying objects, try to normalize
them, currently biased towards strings and floats.
Copy link

@wierdvanderhaar wierdvanderhaar left a comment

Choose a reason for hiding this comment

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

It is a lot but looks good as far as I can see.

@amotl amotl merged commit 62a3bbb into main Sep 10, 2024
22 checks passed
@amotl amotl deleted the zyp-treatments branch September 10, 2024 15:35
@amotl
Copy link
Member Author

amotl commented Sep 10, 2024

Thanks.

It is a lot [...]

Now that fragments have been slotted in here, they don't need to be part of crate/cratedb-toolkit#255, so there became more room for software tests and features over there, if that comforts you a bit? ;]

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

Successfully merging this pull request may close these issues.

2 participants