Coder Social home page Coder Social logo

ProxyFactory#getProxy seems to re-use EVM instances from the cache without properly settings optionalParameters about blaze-persistence HOT 6 CLOSED

EugenMayer avatar EugenMayer commented on July 18, 2024
ProxyFactory#getProxy seems to re-use EVM instances from the cache without properly settings optionalParameters

from blaze-persistence.

Comments (6)

Mobe91 avatar Mobe91 commented on July 18, 2024 1

@EugenMayer would you be able to try if the changes in #1806 solve this?

from blaze-persistence.

Mobe91 avatar Mobe91 commented on July 18, 2024 1

Thank you for the hints. If you are curious, I've opened a spring-boot issue a while ago for this and included quite some details about what I am observing in my case. Reducing the application context cache size was the first thing I did but strangely the application contexts are still not garbage collected even though they are no longer held by the cache.

My tests run in Maven but no parallelism is involved. I might give the EM clearing a try though! 👍

from blaze-persistence.

EugenMayer avatar EugenMayer commented on July 18, 2024

@Mobe91 thank you a lot for working on this item! Will try to queue the test today

from blaze-persistence.

EugenMayer avatar EugenMayer commented on July 18, 2024

@Mobe91 indeed this solves my issue entirely. Did it solve your memory leak issue too?

from blaze-persistence.

Mobe91 avatar Mobe91 commented on July 18, 2024

Did it solve your memory leak issue too?

Unfortunately not, there must be other things going on in my case that are probably not related to blaze-persistence 🥲

Glad to hear that it works for you! @beikov will make sure it goes into the upcoming release.

from blaze-persistence.

EugenMayer avatar EugenMayer commented on July 18, 2024

@Mobe91 AFAIK you are using spring boot in your tests right?

Some aspects we use:

  1. I'am sure you are aware about the context cache and the ability to limit the amount of caches spring boot is preserving during the tests? For us, this has limitted the used memory and connections. spring.test.context.cache.maxSize=5 or similar helps our cause.

  2. In addition, you might want to implement an TestExecutionListener that clears the EM L1 cache after every test or test suite.

  3. Also, if you are using gradle you might tune your test task

    maxParallelForks = 1
    systemProperties['junit.jupiter.execution.parallel.enabled'] = false

We use this for all JPA based tests.

from blaze-persistence.

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.