Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-16103

CodeCache full during gradle run

    XMLWordPrintableJSON

Details

    • Test
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 9.1
    • Build
    • None

    Description

      Running ./gradlew check on main branch, with Java 17.0.2

      org.gradle.workers.max=16
      tests.jvms=16

      I see this error:

      > Task :solr:core:test
      WARNING: A command line option has enabled the Security Manager
      WARNING: The Security Manager is deprecated and will be removed in a future release
      OpenJDK 64-Bit Server VM warning: CodeCache is full. Compiler has been disabled.
      [311.556s][warning][codecache] CodeCache is full. Compiler has been disabled.
      OpenJDK 64-Bit Server VM warning: Try increasing the code cache size using -XX:ReservedCodeCacheSize=
      [311.556s][warning][codecache] Try increasing the code cache size using -XX:ReservedCodeCacheSize=
      CodeCache: size=49152Kb used=49151Kb max_used=49151Kb free=0Kb
       bounds [0x000000011096e000, 0x000000011396e000, 0x000000011396e000]
       total_blobs=21889 nmethods=20939 adapters=872
       compilation: disabled (not enough contiguous free space left)
                    stopped_count=1, restarted_count=0
       full_count=0org.apache.solr.schema.TestCloudSchemaless > initializationError FAILED
          java.lang.VirtualMachineError: Out of space in CodeCache for adapters
              at java.base@17.0.2/java.lang.Class.getDeclaredMethods0(Native Method)
              at java.base@17.0.2/java.lang.Class.privateGetDeclaredMethods(Class.java:3402)
              at java.base@17.0.2/java.lang.Class.getDeclaredMethods(Class.java:2504)
              at app//com.carrotsearch.randomizedtesting.ClassModel$3.members(ClassModel.java:215)
              at app//com.carrotsearch.randomizedtesting.ClassModel$3.members(ClassModel.java:212)
              at app//com.carrotsearch.randomizedtesting.ClassModel$ModelBuilder.build(ClassModel.java:85)
              at app//com.carrotsearch.randomizedtesting.ClassModel.methodsModel(ClassModel.java:224)
              at app//com.carrotsearch.randomizedtesting.ClassModel.<init>(ClassModel.java:207)
              at app//com.carrotsearch.randomizedtesting.RandomizedRunner.<init>(RandomizedRunner.java:321)
              at jdk.internal.reflect.GeneratedConstructorAccessor235.newInstance(Unknown Source)
              at java.base@17.0.2/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
              at java.base@17.0.2/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
              at java.base@17.0.2/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
              at app//org.junit.internal.builders.AnnotatedBuilder.buildRunner(AnnotatedBuilder.java:104)
              at app//org.junit.internal.builders.AnnotatedBuilder.runnerForClass(AnnotatedBuilder.java:86)
              at app//org.junit.runners.model.RunnerBuilder.safeRunnerForClass(RunnerBuilder.java:70)
              at app//org.junit.internal.builders.AllDefaultPossibilitiesBuilder.runnerForClass(AllDefaultPossibilitiesBuilder.java:37)
              at app//org.junit.runners.model.RunnerBuilder.safeRunnerForClass(RunnerBuilder.java:70)
              at app//org.junit.internal.requests.ClassRequest.createRunner(ClassRequest.java:28)
              at app//org.junit.internal.requests.MemoizingRequest.getRunner(MemoizingRequest.java:19)
              at org.gradle.api.internal.tasks.testing.junit.JUnitTestClassExecutor.runTestClass(JUnitTestClassExecutor.java:78)
              at org.gradle.api.internal.tasks.testing.junit.JUnitTestClassExecutor.execute(JUnitTestClassExecutor.java:58)
              at org.gradle.api.internal.tasks.testing.junit.JUnitTestClassExecutor.execute(JUnitTestClassExecutor.java:38)
              at org.gradle.api.internal.tasks.testing.junit.AbstractJUnitTestClassProcessor.processTestClass(AbstractJUnitTestClassProcessor.java:62)
              at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.processTestClass(SuiteTestClassProcessor.java:51)
              at jdk.internal.reflect.GeneratedMethodAccessor45.invoke(Unknown Source)
              at java.base@17.0.2/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.base@17.0.2/java.lang.reflect.Method.invoke(Method.java:568)
              at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:36)
              at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
              at org.gradle.internal.dispatch.ContextClassLoaderDispatch.dispatch(ContextClassLoaderDispatch.java:33)
              at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:94)
              at jdk.proxy1/jdk.proxy1.$Proxy2.processTestClass(Unknown Source)
              at org.gradle.api.internal.tasks.testing.worker.TestWorker$2.run(TestWorker.java:176)
              at org.gradle.api.internal.tasks.testing.worker.TestWorker.executeAndMaintainThreadName(TestWorker.java:129)
              at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:100)
              at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:60)
              at org.gradle.process.internal.worker.child.ActionExecutionWorker.execute(ActionExecutionWorker.java:56)
              at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:133)
              at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:71)
              at app//worker.org.gradle.process.internal.worker.GradleWorkerMain.run(GradleWorkerMain.java:69)
              at app//worker.org.gradle.process.internal.worker.GradleWorkerMain.main(GradleWorkerMain.java:74) 

      Sometimes I get a different error that it's just a test timing out after a bunch of code cache full messages. Sometimes it's in a different test.

       

      I think running other tasks first to reduce the amount of work required by `check` works around this? Hard to tell.

      Attachments

        Issue Links

          Activity

            People

              mdrob Mike Drob
              mdrob Mike Drob
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

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