Skip to content

Instantly share code, notes, and snippets.

Created November 4, 2020 06:40
Show Gist options
  • Save AdamBien/4b9214b29ed1810390bbe7ed303db6c4 to your computer and use it in GitHub Desktop.
Save AdamBien/4b9214b29ed1810390bbe7ed303db6c4 to your computer and use it in GitHub Desktop.

Ask questions and see you at December, 7th, 8.PM. CET:

Also checkout recent episode:


Please keep the questions Jakarta EE-stic. Means: as short and as concise as only possible. Feel free to ask several, shorter questions. Upcoming events are also going to be announced at

Copy link

dabkhazi commented Dec 7, 2020

Hi Adam!
I watched your latest videos and I'm interested in a question about a rest client fault. For example, the task is to periodically send data through the scheduler using rest client, how to properly handle the case of a client crash (fault) so that the scheduler can stop before the client is restored to work? I am thinking of a global flag that stores client state information, maybe failover has a more elegant solution?

Copy link

thehpi commented Dec 7, 2020

I building code where there are data models in different layers of the application which are very much alike. This causes a lot of boilerplate code and unittests which is hard to maintain.

I would like to use some mechanism from which I could generate the model classes and use mapping software to get data from model1 to model2.

What would be a good library which can be configured to

  • generate the different model classes (also the jpa entity classes)
  • do the data mapping for these models

I know about odata but this has its own data model which is another extra model from which I need to map to my internal model(s).
I also know about graphql but I want to use plain REST resources from my client software for now.

Copy link

thehpi commented Dec 7, 2020

I want to be able to configure for a user how many request per second he can fire onto my server.
And my server then should return the nr of possible requests in a response header.
And of course my server should return http response code 429 (too many request) when the max nr requests/sec is depleted.

How would you do this?

Copy link

@thephi did you have a look at Mapstruct (

Copy link

thehpi commented Dec 9, 2020

@ashburnere yes I am investigating it, it is a very elaborate tool but I'm not sure yet if I can use it but it looks promising.

Copy link

As creator of Jwtenizer do you recommend to you clients to implement in-house authentication and authorization workflows? Quarkus JPA Security and JWT Security makes it look like an easy job initially, but I fear things get tough when you realize you need:

  • self-registration
  • login
  • passwordless login
  • profile update
  • forgotten password workflow
  • multi-factor authentication
  • email verification
  • user management UI console

... Or do you recommend external providers such as Okta, Auth0, AWS Cogito?

There is also this up-and-coming German middleware ORY/Kratos, but they are very opinionated, do not recommend JWT tokens and do a lot fo server-side rendering to implement workflows.

What do your clients usually end up doing?

Have you had a look at It probably suites you better?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment