FilteringClassLoaderTest.groovy

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 2 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 2 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 2 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 2 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Simplify daemon groovy compiler classpath filter

  1. … 3 more files in changeset.
Faster classloader filtering using a trie (#6815)

Use Trie to check for package prefixes in filtering classloader

  1. … 9 more files in changeset.
Don't use ClassLoader.getDefinedPackages() on Java 9 (#5477)

Prior to this change, FilteringClassLoader invokes

ClassLoader.getSystemClassLoader().getParent().getDefinedPackages()

to get all system packages on Java 9, which is not correct.

ClassLoader.getDefinedPackages() only fetches packages defined by

the ClassLoader itself, not including its parent's. The consequence is,

on Java 9, most Java SE and JDK packages (e.g. java.lang) are not included in

FilteringClassLoader.SYSTEM_PACKAGES.

This PR fixes this problem by using ClassLoader.getPackages() all the time.

  1. … 4 more files in changeset.
Bump cglib in `buildSrc` too

  1. … 2 more files in changeset.
Ignore SystemPackages test on Java 9

It's not that the underlying code isn't woring, it's just that on Java

9, the `getPackage()` method that the test uses doesn't see the

expected packages.

Switch to FIX_TO_WORK_ON_JAVA9.

- This special-purpose `TestCondition` will make it easier to search the

codebase for problems with running on JDK9.

  1. … 3 more files in changeset.
Just ignore that test on java9.

- Java9 doesn't allow you to count on being able to see nearly as many

things through the system `ClassLoader` as you could with previous

versions of Java. So, it doesn't make sense for us to require that

our `FilteringClassLoader` be able to see this particular resource.

  1. … 1 more file in changeset.
Make `FilteringClassLoader` immutable

`SystemClassLoaderSpec` is moved to its own class so that it can be

included in `gradle-worker.jar`.

+review REVIEW-6020

    • -24
    • +58
    ./FilteringClassLoaderTest.groovy
  1. … 20 more files in changeset.
Revert "Make `FilteringClassLoader` immutable"

This reverts commit 18ee27f8561df18b19761ebd65f209eed88c19f5.

    • -58
    • +24
    ./FilteringClassLoaderTest.groovy
  1. … 15 more files in changeset.
Make `FilteringClassLoader` immutable

+review REVIEW-6020

    • -24
    • +58
    ./FilteringClassLoaderTest.groovy
  1. … 15 more files in changeset.
Add more checks to the disallow package tests

+review REVIEW-5379

Fix spec copying in FilteringClassLoader

+review REVIEW-5379

  1. … 1 more file in changeset.
Add disallowPackage to FilteringClassLoader

Like disallowClass, but applies to packages and subpackages.

+review REVIEW-5379

  1. … 3 more files in changeset.
Not sure why these weren't included in the merge

  1. … 2 more files in changeset.
Merge branch 'release'

  1. … 3 more files in changeset.
Attempt to make test work on Java 5 and on IBM JDK by not using Objenesis for ClassLoader mock… whatever that is.

Can't mock class loaders on IBM JDK.

Can't mock class loaders on IBM JDK.