I haven’t looked closely into the code, just judged from the error stack trace. Most likely the configuration injection point for PTM in this module does not use a specific discriminator value to differentiate which bean instance to use. Again, just a guess without looking deeply into the code.
D. On Wed, Aug 7, 2024 at 12:12 David Reagan <reag...@lanecc.edu> wrote: > Removing `implementation "org.apereo.cas:cas-server-support-session-jdbc"` > from build.gradle did get me past the error. > > That did resolve the PlatformTransactionManager error. > > Can I ask why removing that module helped? > > I'm still testing things, but I thought having sessions stored in the db > would be a good initial setup until I figured out HA. > > Thanks! > > - David > > On Wednesday, August 7, 2024 at 3:01:17 AM UTC-7 Dmitriy Kopylenko wrote: > >> Try getting rid of this dependency from build.gradle: >> >> implementation "org.apereo.cas:cas-server-support-session-jdbc" >> >> >> On Tue, Aug 6, 2024 at 21:06 David Reagan <rea...@lanecc.edu> wrote: >> >>> I've been trying to get a basic standalone instance of CAS set up using >>> a MariaDB db for storage. Just as a proof of concept before I move on to >>> getting it running in HA mode. But I keep getting stuck when I get to the >>> point of trying to load the /cas/login page. >>> >>> I'm getting a very perplexing error about CAS not being able to find a >>> unique `org.springframework.transaction.PlatformTransactionManager` because >>> there are multiple classes defined for that. >>> >>> *My Setup:* >>> >>> I used the Initializer to generate the overlay project. The CAS Overlay >>> option, version 7.0.6, executable deployment type, and only the Shell >>> option checked. >>> >>> I have a MariaDB 11.2 container specifically for CAS serving as the >>> database storage target. >>> >>> Since this is part of a larger project, I've been building the war file >>> and adding it to a Docker image based on Ubuntu 22.04 with openjdk 21 >>> installed. The actual start up is managed by s6-overlay (part of my default >>> tools, it lets me run pre-startup scripts to help configure things and keep >>> secrets from being committed to git or the image.) >>> >>> For testing I've just been copying the overlay etc/cas directory to a >>> Docker volume mounted on the container at /etc/cas. Then stopping and >>> starting the container if I haven't changed anything in build.gradle, if I >>> have changed build.gradle, I rebuild the image before starting the >>> container again. >>> >>> *Troubleshooting:* >>> >>> While troubleshooting this error, all my web search results seem to be >>> only applicable if you are developing Java apps, since the solutions >>> involve annotating the class you want to use properly. >>> >>> Since I'm just configuring CAS, I'm pretty sure annotating a class is >>> not the solution to my issue. >>> >>> The closest CAS related result I found is this thread: >>> https://groups.google.com/a/apereo.org/g/cas-user/c/j7QrsUo19jo/m/qZQqHy6UAgAJ >>> The suggested solution is to add `-Dspring.index.ignore=true` to the start >>> up of CAS. That, as far as I can tell, did nothing for my issue. >>> >>> I've been through every doc page I think is related to the modules I've >>> included in the overlay looking for any missing configuration that might >>> help. But I'll freely admit that I can't be sure I've found everything. The >>> algolia search generally does not provide useful results, and DuckDuckGo >>> doesn't seem to do a very good job when I search for the module based on >>> what it's called in build.gradle. Plus, I've yet to figure out how to >>> properly connect the dependency names in Initializer with what the >>> documentation is called... >>> >>> I've tried disabling a bunch of the modules, but even if I only have (I >>> think) jdbc search, ticket registry, and service registry, enabled, I still >>> get the error. The only difference is it finds 3 (or something like that) >>> `org.springframework.transaction.PlatformTransactionManager` instead of 8. >>> >>> I also dug through the file generated by the exportConfigMetadata >>> gradlew task (that's the one that dumps all the config options into a file >>> with lots of comments.) >>> >>> Even JetBrains AI hasn't been able to get me through this. >>> >>> At this point I'm just reading the same thing over again or doing the >>> same test over again. Not actually doing anything useful. >>> >>> Could someone take a look at my stuff and point out what I'm missing, or >>> suggest things to try? >>> >>> Here https://pastebin.com/meTYdwAf is a pastebin of the most everything >>> I think you might need. Including the logs from starting the container to >>> when it errors, build.gradle, gradle.properties, settings.gradle, my >>> Dockerfile, how I build, etc. I tried to apply markdown formatting, but >>> that's paid, and I don't use pastebin often enough for that... I did >>> sanitize things even though everything was dev mode and would get tossed >>> out... >>> >>> Thanks for any insight you can provide. >>> >>> - David >> >> -- >>> - Website: https://apereo.github.io/cas >>> - List Guidelines: https://goo.gl/1VRrw7 >>> - Contributions: https://goo.gl/mh7qDG >>> --- >>> You received this message because you are subscribed to the Google >>> Groups "CAS Community" group. >>> To unsubscribe from this group and stop receiving emails from it, send >>> an email to cas-user+u...@apereo.org. >>> To view this discussion on the web visit >>> https://groups.google.com/a/apereo.org/d/msgid/cas-user/c8784276-f767-4b8f-a1cd-4bce236f833fn%40apereo.org >>> <https://groups.google.com/a/apereo.org/d/msgid/cas-user/c8784276-f767-4b8f-a1cd-4bce236f833fn%40apereo.org?utm_medium=email&utm_source=footer> >>> . >>> >> -- > - Website: https://apereo.github.io/cas > - List Guidelines: https://goo.gl/1VRrw7 > - Contributions: https://goo.gl/mh7qDG > --- > You received this message because you are subscribed to the Google Groups > "CAS Community" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to cas-user+unsubscr...@apereo.org. > To view this discussion on the web visit > https://groups.google.com/a/apereo.org/d/msgid/cas-user/3a039d24-4075-47c2-9719-1ab762b757b7n%40apereo.org > <https://groups.google.com/a/apereo.org/d/msgid/cas-user/3a039d24-4075-47c2-9719-1ab762b757b7n%40apereo.org?utm_medium=email&utm_source=footer> > . > -- - Website: https://apereo.github.io/cas - List Guidelines: https://goo.gl/1VRrw7 - Contributions: https://goo.gl/mh7qDG --- You received this message because you are subscribed to the Google Groups "CAS Community" group. To unsubscribe from this group and stop receiving emails from it, send an email to cas-user+unsubscr...@apereo.org. To view this discussion on the web visit https://groups.google.com/a/apereo.org/d/msgid/cas-user/CAMpiYKi0kJNy4b1dQDwcepQtqWguoi6rqbGorct%3Dv1v_xwMqAQ%40mail.gmail.com.