-
1. Re: 9.0.0.final with Spring Boot
sebastian.laskawiec May 19, 2017 2:47 AM (in response to adrian.p.smith1)Uber Jars (such as infinispan-embedded) aim for simple deployment scenarios. Your app seems to be a bit more complicated and therefore you'd probably need to use inifinispan-spring-boot-starter + infinispan-core + infinispan-spring4-embedded or just inifinispan-spring-boot-starter for client/server scenario.
If that won't work, could you please paste me your dependency tree (obtained by mvn dependency:tree)?
-
2. Re: 9.0.0.final with Spring Boot
adrian.p.smith1 May 19, 2017 4:37 AM (in response to sebastian.laskawiec)Thanks for the reply.
FYI - using Gradle I find that if I have a dependency for the embedded jar also brings in core and many others as additional dependencies. Not sure if this is what's intended?
Anyhow, I have changed to just using core and that makes life easier - so thanks for that.
I'm interested in using the spring-boot-starter, but some of the documentation is a little lightweight at the moment. I attach my Java based Spring configuration below and wonder if you have any comments about it in general and, in particular, if I could achieve the same using the Spring-Boot starter?
-
InfinispanConfiguration.java 4.0 KB
-
-
3. Re: 9.0.0.final with Spring Boot
sebastian.laskawiec May 19, 2017 7:53 AM (in response to adrian.p.smith1)FYI - using Gradle I find that if I have a dependency for the embedded jar also brings in core and many others as additional dependencies. Not sure if this is what's intended?
Definitely not! It's a bug. I created [ISPN-7849] Uber jars have lots of compile-time dependencies - JBoss Issue Tracker to fix it. In the meantime, feel free to exclude all those compile-time dependencies. The Uber Jar should work without them (but those provided are necessary, those are APIs).
Thanks for noticing it. I don't know how it got slipped under our radar.
Anyhow, I have changed to just using core and that makes life easier - so thanks for that.
This is the suggested way... try it out with Uber Jars but when in trouble, switch to small jars.
I'm interested in using the spring-boot-starter, but some of the documentation is a little lightweight at the moment. I attach my Java based Spring configuration below and wonder if you have any comments about it in general and, in particular, if I could achieve the same using the Spring-Boot starter?
You could probably use InfinispanCacheConfigurer to replace defaultCacheManager producer. Apart from that and simplifying dependencies tree there's not much you can do. Your configuration is pretty advanced. I personally would even leave all the configuration bits as they are now (but please take this advice with a grain of salt, I don't know much about your use case).
-
4. Re: 9.0.0.final with Spring Boot
galder.zamarreno May 24, 2017 7:26 AM (in response to sebastian.laskawiec)I've seen some examples out there of uber jars in maven projects. This is not recommended as you can see.
If using gradle/maven, just don't use uber jars. Uber jars are for those still on ant or more lower level tools.