Git Product home page Git Product logo

Comments (5)

jjlauer avatar jjlauer commented on July 4, 2024

You've submitted a couple classloader PRs, but perhaps it'd be good to try and create unit tests to verify all this. Running under maven, tomcat, gradle, etc. introduce all sorts of interesting classloader issues and it'd be good to have some coverage of what you're attempting to solve. I'm supportive of your effort to let you passthru the classloader, but I'd love your help making sure we don't regress in future versions.

from rocker.

ldaley avatar ldaley commented on July 4, 2024

If you can give some guidance about how the testing works for this project, I'll gladly contribute tests. I could quite work it out on my own.

Just to be clear, there's no PR for this one. The change is debatable, so I wanted to discuss first.

from rocker.

jjlauer avatar jjlauer commented on July 4, 2024

Unit tests for runtime classes are all on runtime/src/test/java. Any changes affecting a classloader for those classes in that module would go in there.

Unit/integration tests that target Java 6+ compatibility all go in java6tests/src/test/java. I'd foresee some of your classloading changes needing to be tested in here.

Unit/integration tests that target Java 8+ compatibility all go in java8tests/src/test/java. I doubt any classloader tests would need to go in there.

Testing classloaders is complicated as many of the issues only seem triggered in the environment the project runs in. So we'd need to figure out a good way of mocking up what those look like and then confirming the various parts of the project work under that type of classloader.

from rocker.

ssijak avatar ssijak commented on July 4, 2024

I experience the same problem. Because Rocker uses its own classloaders, they cant see .class files in Play Framework 1.x (I guess 2.x is the same) project. Because Play messes with classpaths and has dev and prod environments where in dev it autocompiles and reloads stuff in memory, and in prod it will precompile, we must use Play.classLoader to load the classes.

from rocker.

jjlauer avatar jjlauer commented on July 4, 2024

Hi @ssijak - when rocker's hot reloading feature is turned off (as it should be in prod) - the only special classloader used is to load up the byte arrays of static template content. Even if Play uses its own classloader, I wouldn't think that would conflict. So to be clear -- are you having issues in dev or prod? If its just dev -- have you turned off hot reloading to see if that works?

from rocker.

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.