[DOCS-10519] "use-cases/storing-comments": how to get the "path" list Created: 13/Jul/17  Updated: 30/Oct/23

Status: Closed
Project: Documentation
Component/s: manual, Server
Affects Version/s: None
Fix Version/s: Server_Docs_20231030

Type: Bug Priority: Major - P3
Reporter: Docs Collector User (Inactive) Assignee: Unassigned
Resolution: Won't Do Votes: 0
Labels: collector-298ba4e7, docs-triage
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Linux mint x86-64bit.

Location: https://docs.mongodb.com/ecosystem/use-cases/storing-comments/#embedding-all-comments
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36
Referrer: https://docs.mongodb.com/ecosystem/use-cases/storing-comments/
Screen Resolution: 1920 x 1080


Participants:
Days since reply: 1 year, 14 weeks, 2 days ago
Epic Link: DOCSP-1769

 Description   

Hi, In the "embedding all comments in one document" part, for threaded discussions, you mentioned
that "To reply to a comment, the following code assumes that it can retrieve the ‘path’ as a list of positions",
which is really a clever idea, but the thing is I can't find a practical way to get the path list.

I've considered maintaining a field named internalPath which demonstrate the path of the comment in the whole tree,
but it seems impractical to do so because it's very hard for mongodb to find each comment's index in the arrays given
the depth of the whole tree.

And I've considered maintaining the path in frontend, which is not as hard to implement as doing it in database level,
but that will certainly decrease the reliability, right?

So my question is how to retrieve the 'path' list.

Looking forward your reply, thanks.



 Comments   
Comment by Education Bot [ 31/Oct/22 ]

Hello! This ticket has been closed due to inactivity. If you believe this ticket is still important, please reopen it and leave a comment to explain why. Thank you!

Generated at Thu Feb 08 08:00:45 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.