[keycloak-user] 3.4.3.Final Resolve java.lang.NoClassDefFoundError: org/keycloak/authorization/client/Configuration in custom authenticator

Pedro Igor Silva psilva at redhat.com
Tue Jun 26 13:31:50 EDT 2018


No problem.

The keycloak-authz-client has only a few deps which are basically those
already available on the server.  If you don't want a fat jar you could
have a META-INF/jboss-deployment-strucuture.xml referencing the modules you
want to have available to your deployment. Just make sure to set up the
keycloak-authz-client on the server, you can use this module definition [1].

[1]
https://github.com/pedroigor/keycloak/blob/6d8a3f7a8b644ebd6b09000c5ec5670e3906caeb/distribution/feature-packs/adapter-feature-pack/src/main/resources/modules/system/add-ons/keycloak/org/keycloak/keycloak-authz-client/main/module.xml


On Tue, Jun 26, 2018 at 1:47 PM, Jeremy Giberson <
jeremy.giberson at privoro.com> wrote:

> Sorry for the remedial question — but what would be the best method to
> accomplish that? (Keycloak is the first and only java dev stack in our
> ecosystem so I’m a fish out of water).
>
> Im currently exploring making a “fat” jar. I’ve seen a few articles
> suggesting different maven plugins to accomplish this. But is this the best
> means? Seems like this would include all the dependences rather than just
> the one I’m missing.
>
> If you have any guidance it would be greatly appreciated.
>
>
> On Jun 26, 2018, at 9:38 AM, Pedro Igor Silva <psilva at redhat.com> wrote:
>
> Maybe we are missing the library as a runtime library (not only compile if
> you just added it to your project) ?
>
> On Tue, Jun 26, 2018 at 1:23 PM, Jeremy Giberson <
> jeremy.giberson at privoro.com> wrote:
>
>> Hello,
>> I’m wondering how I can resolve the error: "Uncaught server error:
>> java.lang.NoClassDefFoundError: org/keycloak/authorization/client/Configuration”
>> being thrown in my custom authenticator. This started occurring after we
>> added the dependency "
>> keycloak-authz-client” to our project so we can utilize the AuthzClient
>> class.
>>
>> I’m hoping to utilize the hot deployment option of moving my compiled jar
>> into the deployments folder.
>> _______________________________________________
>> keycloak-user mailing list
>> keycloak-user at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/keycloak-user
>>
>
>
>


More information about the keycloak-user mailing list