5 Tips for Building your Java API

5 Tips for Building your Java API

Five tips that will save you time and code, along with making your Java applications more secure and easier to maintain.


From the tutorials that I can see, I was just wondering why there is so much configuration and coding is needed with OKTA?

This does not help with code minimization, isn’t it? In reality, it’s like download a number of dependencies,
configure in a number of places, plug-in to some exiting codes, write some new piece of codes, add some users to some groups etc etc. And with one piece missing, the whole thing is just broken. One the other hand, think about a traditional way: if you have a web form user userid/password as input, it is authenticated and authorized against your LDAP (and Database) and if matches, you are permitted to navigate inside the website. Now much of a code saving, isn’t it? The same or even more.

Matt Raible

There’s not much configuration or coding needed to create a Spring Boot app that integrates with Okta. You can create the app with Okta included as a dependency using cURL.

curl https://start.spring.io/starter.zip <br> -d dependencies=web,okta <br> -d packageName=com.okta.developer <br> -d name=quick-app <br> -d type=maven-project <br> -o quick-java-app.zip

Then you can unzip the project, navigate to it from a command line, and use the Okta Maven Plugin to create an account + configure your app.

mvn com.okta:okta-maven-plugin:setup

I doubt you can setup an LDAP server and configure Spring Boot to talk to it that fast. :wink: