Building Keycloak on Mac - benchmarks

31 views
Skip to first unread message

Francis Augusto Medeiros

unread,
Feb 10, 2023, 12:23:02 PM2/10/23
to Keycloak Dev
Hi,

I have recently sent a PR with a code proposal, and it was the first time I ran maven on Mac.

I thought about sharing this here, and wonder if others have their benchmarks to share.

My first odd found was that there was no difference between the M1 Pro and M1 Max when it comes to speed.

The second, a bit obvious, is that running multiple threads helps building without tests, but marginally when tests are included:

                m1 pro      m1 max
without tests   01:57       02m06s
with tests      01h35m       01h33m

Threads
without tests   01m20s      01m:20s
with tests      01h34m       01h31m


Any possible optimization on the Mac to make it run a bit faster?

Thomas Darimont

unread,
Feb 10, 2023, 2:16:24 PM2/10/23
to Keycloak Dev
Hello Francis,

you could try to build keycloak with mvnd https://github.com/apache/maven-mvnd 
this usually speeds up things quite a bit.

Cheers,
Thomas

Václav Muzikář

unread,
Feb 13, 2023, 4:24:45 AM2/13/23
to Thomas Darimont, Keycloak Dev
Hello,
I believe the reason why multiple threads don't help much when running tests is they don't run in parallel, so you are basically bottlenecked by single thread performance which is similar for both M1 Max and Pro. Currently, I don't think we support parallel runs out-of-the-box.

--
You received this message because you are subscribed to the Google Groups "Keycloak Dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to keycloak-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/keycloak-dev/6f3e6c33-385c-4db9-83cc-cb951083c99en%40googlegroups.com.


--
Václav Muzikář
Senior Software Engineer
Keycloak / Red Hat Single Sign-On
Red Hat Czech s.r.o.

Francis Augusto Medeiros

unread,
Aug 25, 2023, 9:36:17 AM8/25/23
to Keycloak Dev
Hi,

I’m considering writing a small Authenticator SPI to deal with 2FA. We have our secrets in a Microsoft Radius (NPS) server. This allows our users to choose token-based or push notifications as 2FA methods.

I have two doubts:

- Since the credential (OTP) won’t be stored in Keycloak, do I still need to implement `org.keycloak.credential.CredentialProvider` and a `org.keycloak.credential.CredentialModel`?
- I want to be able to check if the user has push notifications enabled or if he/she will have to input a code. Is there a way for me to check that in one of my codes so that I can set up a property/attribute which can be used on the HTML template to hide/show the text field to input a numeric token?

Best,
Francis

Francis Augusto Medeiros

unread,
Aug 25, 2023, 9:53:51 AM8/25/23
to Keycloak Dev
Reply all
Reply to author
Forward
0 new messages