[MGNLREST-370] Support fetching data by nodeTypes Created: 06/May/22  Updated: 26/Sep/22  Resolved: 17/Aug/22

Status: Closed
Project: Magnolia REST Framework
Component/s: None
Affects Version/s: None
Fix Version/s: 3.0.0

Type: Story Priority: Neutral
Reporter: Oanh Thai Hoang Assignee: Rishab Dhar
Resolution: Fixed Votes: 0
Labels: None
Σ Remaining Estimate: Not Specified Remaining Estimate: Not Specified
Σ Time Spent: 3h Time Spent: Not Specified
Σ Original Estimate: Not Specified Original Estimate: Not Specified

Attachments: PNG File sample-filtering-nodetype-s.png    
Issue Links:
Cloners
clones MGNLREST-368 Support includeSystemProperties, syst... Closed
is cloned by MGNLREST-371 Support fetching data by childNodeTypes Closed
Sub-Tasks:
Key
Summary
Type
Status
Assignee
MGNLREST-407 Implement Technical task Closed Rishab Dhar  
MGNLREST-408 Review Technical task Completed Canh Nguyen  
MGNLREST-409 PiQA Technical task Closed Oanh Thai Hoang  
MGNLREST-410 QA Technical task Completed Dai Ha  
Template:
Acceptance criteria:
Empty
Task DoD:
[X]* Doc/release notes changes? Comment present?
[X]* Downstream builds green?
[X]* Solution information and context easily available?
[X]* Tests
[X]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Date of First Response:
Epic Link: Norsu delivery endpoint (phase 1)
Sprint: DevX 16
Story Points: 3
Team: DeveloperX

 Description   

Norsu consider store nodetypes in labels column. See

 

Currently, nodetype when serializing does not support yet. We should map correct nodetype from metadata labels to nodetype property

Example use case

AC:

Implement the filtering nodetype in database level since nodetype will be labels in labels column

 



 Comments   
Comment by Christopher Zimmermann [ 16/May/22 ]

Will we also get the "@nodeType" property as a top level property? Thinking about the API being compatible with JCR v2 delivery endpoint.

Comment by Oanh Thai Hoang [ 17/May/22 ]

Hi czimmermann, absolutely yes. "@nodeType" property will be a top level property

Comment by Rishab Dhar [ 02/Jun/22 ]

Currently, the API for filtering by multiple nodeTypes is not available on norsu as mentioned by sasha below.

How can we request for an OR value for a specific label - for example where primaryType is one of mgnl:page mgnl:area or mgnl:component?

> currently this is not yet implemented, you can file a proposal ticket (I would imagine the fluent api method that instead of a concrete label value would take some special object like withLabel(<key>, anyOf(<values>))
btw, fwiw, now to retrieve the page content, you don’t need to specify that you’re looking for areas/components
explicitly - it is assumed that areas and components are the nested parts of a page (not separate nodes that is)

For now, he recommends, filtering by single value:

I’d suggest to start simple and stick with a singular value for now

Generated at Mon Feb 12 06:59:15 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.