Coder Social home page Coder Social logo

Comments (4)

kbrabrand avatar kbrabrand commented on July 19, 2024

My vote goes to number three. It looks a bit messy now, but adding a few use statements will shorten the code considerably. I think the slightly more rigid parsing and rule set is a good thing in this case.

We need to at least implement the $exists operator and a wildcard operator was mentioned, but I'm not sure what operator was used for wildcards in the end. Should check the implementation by @christeredvartsen and implement the same set of operators.

from imbo-metadata-search.

fangel avatar fangel commented on July 19, 2024

Yes. Mongo already has support for $exists in their Query DSL, so our subset will just have to include this too.

The Mongo Query-DSL does not have (as far as I know) support for a $wildcard operator, so technically speaking, our DSL won't be a subset of Mongos - but hey. $wildcard can however be emulated using $regex, so Mongo does support it, albeit with a different syntax. So it's fine for us to have it, as all of our search backends can support it (SQL would likely have to be some sort of LIKE, which is slow but functional).

from imbo-metadata-search.

kbrabrand avatar kbrabrand commented on July 19, 2024

I don't know how you planned to implement the AST building and handling, but I looked into a few different alternatives and Dissect seems to provide a pretty straight forward way of building and working with ASTs. Just a thought.

from imbo-metadata-search.

fangel avatar fangel commented on July 19, 2024

Closing this issue, as we now have a a good start to an implementation that follows option 3.

from imbo-metadata-search.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.