umbraco / Umbraco-CMS

Umbraco is a free and open source .NET content management system helping you deliver delightful digital experiences.
https://umbraco.com
MIT License
4.42k stars 2.67k forks source link

.TypedContent gets IPublishedContent with invalid child node #11746

Closed mjolicseven closed 2 years ago

mjolicseven commented 2 years ago

Which exact Umbraco version are you using? For example: 9.0.1 - don't just write v9

7.15.7

Bug summary

Let me give a brief introduction on how our content is structured in the Umbraco CMS: We have an Episode node, that's parent node. Beneath that node we have a VideoAsset node (defined as UmbracoProperty), which is child node. We tracked the root cause of this issue and found out that the call to method ".TypedContent(int id);" (parameter ID was the episode's one) from "Umbraco.Web" assembly returned back a wrong child video asset. However, everything looks okay in the database. Screenshot_1 Screenshot_2

.

Specifics

No response

Steps to reproduce

We have an endpoint which is getting Episode (IPublishedContent) by Id from the CMS and sending SNS message to our other services. In small period of time we're sending over a 1k requests to this endpoint, picking up content and sending SNS message.

  1. Umbraco api endpoint receives message with specific document id
  2. typedPublishedContentQuery.TypedContent(Id); is being called
  3. IPublishedContent for that specific item contains wrong property (that single child property is part of the other episode). We noticed that for a couple of episodes. (10 in 1000 lets say)

**UPDATE: Meanwhile during the process we're casting IPublishedContent to specific Model using Ditto - Ditto** might be the issue.

Expected result / actual result

No response

meyntony commented 2 years ago

https://github.com/umco/umbraco-ditto/issues

Sounds like this issue should be reported on the above issue tracker.

mjolicseven commented 2 years ago

Thanks Tony. I will report issue there.