question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support for Dynamic collection

See original GitHub issue

Hi,

My users can Comment on Questions, Feedback, and other Comments.

Every document in the Comments collection therefore has a “forCollection” field, so I can know which Collection a specific comment-doc has as parent.

If a user Comments on a Questions-doc, then that comment-doc will have its forCollection field set to Questions. Likewise, forCollection is set to Feedback if a comment is made on a Feedback document.

So, basically, a comment can belong to many different mongo Collections. How to use Grapher in this situation?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
theodorDiaconucommented, Dec 4, 2017

create multiple links:

commentId, questionId, feedbackId inside the comment, and in their inversed side as well for easy fetching.

0reactions
theodorDiaconucommented, Dec 4, 2017

@Herteby I think that using your approach can also work, and you’re right the .find() will be heavier because it will search through more ‘link_id’ s when trying to fetch from inversed side.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Working with Dynamic Collections - TownNews.com
Dynamic Collections are a method of creating collections in BLOX CMS that uses a search to populate its contents. Prior to our release...
Read more >
Dynamic Collection - Architecture - SearchBlox
SearchBlox can index web content generated dynamically using JavaScript or applications (Single Page Applications SPAs). Dynamic Collection indexing is ...
Read more >
Create Dynamic Collection Ads
The Dynamic Collection Ad supports both Dynamic Ads and Single Image or Video Ads for the Top Snap. All formats support Showcase with...
Read more >
Creating a Dynamic collection with multiple and AND / OR ...
I have Dynamic collection A and B, and they are sufficient for my needs. I am trying to create Collection C as a...
Read more >
Why Are Dynamic Collections So Cool? How to Create/Filter a ...
Dynamic collections will update or refresh the members based on a set of rules or query that you set. This can be helpful...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found