Giter VIP home page Giter VIP logo

Comments (9)

rustyswayne avatar rustyswayne commented on July 28, 2024

Follow up - Looks like a little caching issue. In my case, I had the headline originally on the Home content type and needed to use it on several other pages so I created the second content type "LandingPageHeading" to use in a composition for several other pages.

Doing this straight through the back office does not update the mapping but once the application pool resets, everything works as expected.

from umbraco-ditto.

leekelleher avatar leekelleher commented on July 28, 2024

Thanks @rustyswayne, I'll take a look. Sounds like we're aggressively caching. I'll keep you posted.

from umbraco-ditto.

JimBobSquarePants avatar JimBobSquarePants commented on July 28, 2024

@leekelleher @rustyswayne Agreed. Looks to me like this is the issue.

https://github.com/leekelleher/umbraco-ditto/blob/a825ca870d3f4a87c6ec6d08b73a7cffad41b73c/src/Our.Umbraco.Ditto.ModelFactory/DittoPublishedContentModelFactory.cs#L81

Making the Dictionary internal static and rebuilding it out in an event handler would probably do the trick.

from umbraco-ditto.

JimBobSquarePants avatar JimBobSquarePants commented on July 28, 2024

Hi @rustyswayne I've been having a look at this again and I'm going to need a little bit more information to see what is going on and how best to avoid the issue.

As I understand it you were moving a property from your Home document type into a composite LandingPage document type. You did all this through the back office.

Were there any code changes to prompt a rebuild during this change?

I'm trying to figure out why the ApplicationStarting event is not getting triggered if so.

from umbraco-ditto.

leekelleher avatar leekelleher commented on July 28, 2024

Just having a look over our model-factory code to see what the issue might be, but I'm struggling to figure out what we're caching that could be effected by this?

In the DittoPublishedContentModelFactory class, we have a private dictionary lookup called converterCache, which contains a DocType alias and a Func<> - in which the Func<> is only a call to .As(). So I can't see how changes to DocTypes in the back-office would affect this.

Ditto works purely from the IPublishedContent object, not the DocType... so I'm unsure where the caching issue is happening.


@rustyswayne - do you still see this as an issue, or a glitch that happened during dev?

from umbraco-ditto.

JimBobSquarePants avatar JimBobSquarePants commented on July 28, 2024

@leekelleher That matches my analysis so far also.

from umbraco-ditto.

rustyswayne avatar rustyswayne commented on July 28, 2024

@JimBobSquarePants - sorry I missed your comment a week ago. In regards to ApplicationStarting event, all I did was to put a space in the web.config (and save) to check to see if it might be a run time cache issue.

@leekelleher Once I got the cache cleared I have not seen the issue again, albeit I have not made any changes either.

It may have been a glitch in dev ... if I see it again when I work with it next, I'll come back and comment on the issue.

from umbraco-ditto.

leekelleher avatar leekelleher commented on July 28, 2024

Thanks @rustyswayne.

I'll set this issue as closed, then it can be reopened if happens again.

from umbraco-ditto.

JimBobSquarePants avatar JimBobSquarePants commented on July 28, 2024

@rustyswayne No worries. If anything comes up again give us a shout.

from umbraco-ditto.

Related Issues (20)

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.