Freeze during OST generation

Issue #1763 resolved
Scott Wells repo owner created an issue

I've had a user report a freeze while generating the OST. Based on thread dumps, this seems to occur while adapting custom Apex classes from the org into stub Apex classes for the OST. I'm using this issue to help provide test builds to the user as we try to ascertain the problem and its fix.

Comments (10)

  1. Scott Wells reporter

    This build changes the way that type names are adapted for custom classes given that that's where the provided thread dumps seem to terminate.

    Please download it--down extract it--and install it using Settings/Preferences>Plugins>Install plugin from disk (under the gear drop-down menu). Then please regenerate your OST and let me know whether it completes or freezes the same way. If the latter, please provide new logs/thread dumps.

  2. Scott Wells reporter

    Hi, Cesar. I didn't know others were having this issue since I'd only heard about it from one person. I'm glad to hear that because, as I mentioned to that person, this is happening in code that hasn't changed in over three years, so it seemed quite anomalous. Knowing that it's happening to more than one person is obviously not good--because it means that it's likely happening to more than two people!--but it's also good because it means that it's not a total one-off behavior.

    Go ahead and stay on this build while I test the change so that it can be included in an official release shortly.

  3. Cesar Parra

    Sounds good! I’ll stay with this build. This post and your fix was already up by the time I started noticing the issue 🙂

  4. Scott Wells reporter

    I was able to reproduce this by generating the OST for a quite large project with none of the Apex classes pulled into the local project. In other words, IC is creating stub versions of all custom classes in the org. And it's not a complete freeze; it's just a VERY slow execution such that it's effectively only marginally better than a freeze.

    I'm going to allow this to complete so that I can continue to A/B test the OST contents with and without the changes from this fix. Once I feel comfortable with the change I'll issue a new official build with this fix and one other that I have on deck.

  5. Scott Wells reporter

    Do all of you have MetadataService in your project? Or some similarly huge Apex class file? That's what was causing this seeming freeze for me. I know that the other reporter uses that class. How about you, Cesar?

  6. Cesar Parra

    Yes and no 😅 . It is not in my project but it is on the org, added through an Unlocked package. The class itself within the unlocked package is not global, so I’m not sure if that gets picked up by IC or not.

  7. Scott Wells reporter

    Yep, that would do it. Now I see the common thread. Okay, I've confirmed that to be the case--and would be the case with similarly-sized classes, though I've never seen another one even close--and also that the prospective fix attached to this issue does take care of it nicely. Thanks for confirming! It's good to have a better understanding of what's going on.

  8. Log in to comment