Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-9112

Clean bad smell in `GroovyClassLoader`

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.0.0-beta-2
    • Component/s: None
    • Labels:

      Description

      The type of classCache can not represent its true responsibility:
      protected final Map<String, Class> classCache = new UnlimitedConcurrentCache<String, Class>();

      So I propose to change the type to EvictableCache<String, Class>

      Similarly,  protected final Map<String, Class> sourceCache = new StampedCommonCache<String, Class>(); has the same bad smell

      It will be a breaking change, but it is time to clean the historical bad smell in a big version like Groovy 3.0.0

        Attachments

          Activity

            People

            • Assignee:
              daniel_sun Daniel Sun
              Reporter:
              daniel_sun Daniel Sun

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 20m
                20m

                  Issue deployment