gavlyukovskiy / spring-boot-data-source-decorator

Spring Boot integration with p6spy, datasource-proxy, flexy-pool and spring-cloud-sleuth
Apache License 2.0
870 stars 83 forks source link

datasource still being wrapped despite disabled datasource decoration #107

Open jorgheymans opened 1 month ago

jorgheymans commented 1 month ago

Even though application.yml has this:

decorator:
  datasource:
    enabled: false

We still see that datasource-proxy is decorating the datasource in a stacktrace, is this expected ?

at jdk.internal.reflect.GeneratedMethodAccessor268.invoke(Unknown Source)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.base/java.lang.reflect.Method.invoke(Method.java:569)
    at net.ttddyy.dsproxy.proxy.StatementProxyLogic.performProxyLogic(StatementProxyLogic.java:287)
    at net.ttddyy.dsproxy.proxy.ProxyLogicSupport.proceedMethodExecution(ProxyLogicSupport.java:103)
    at net.ttddyy.dsproxy.proxy.StatementProxyLogic.invoke(StatementProxyLogic.java:119)
    at net.ttddyy.dsproxy.proxy.jdk.PreparedStatementInvocationHandler.invoke(PreparedStatementInvocationHandler.java:37)
    at jdk.proxy4/jdk.proxy4.$Proxy216.executeBatch(Unknown Source)
    at org.hibernate.engine.jdbc.batch.internal.BatchImpl.lambda$performExecution$2(BatchImpl.java:279)
gavlyukovskiy commented 1 month ago

@jorgheymans perhaps there's another starter that does the wrapping? Can you verify that by posting the dependencies of your project or replace the dependency on my starter with dependency on datasource-proxy alone?