Handling exceptions is a crucial part when developing any sort of application, certain errors occur by calling a method of a library with invalid arguments, others happen just for doing something wrong. However, some exceptions can be thrown by ourselves because what was asked to be done by us is not possible.
In the previous post, we developed a simple Web API using Kotlin and Spring, this API allowed us to request and alter information about books in our system, however, when errors are thrown, the information sent to the API client is not the clearest, who becomes unaware of…
For those of you who don’t know, Kotlin is a statically typed programming language designed by Jetbrains, it’s the official language for the development of native android applications, but what you may not know is that you can use Kotlin to develop your server-side applications.
There are many libraries and frameworks which allow you to create your backend using Kotlin, such as Ktor and Spring.
In this article, we will take a look into using Kotlin together with the Spring framework.
Spring is an application framework and inversion of control container(IOC) for the Java platform, however, Spring also allows the…
Understanding what Integrity, Authentication, and Non-Repudiation are, and how we guarantee those properties when sending information to somebody else.
So let’s say you send messages to your friends through your own personal communication channel, you won’t send confidential information so you really don’t care if someone else sees it, however, you want to receive exactly what your friends send to you, you don’t want to receive something else. And sometimes, you really want to guarantee that it was that specific friend who sent you that message.
The code used in the examples was written in Java, using the JCA (Java…
The repository pattern is an abstraction used to hide the multiple data sources we may have in our application, data in an application may come from an internal database, or, an external service such as a Web API.
This pattern is adopted and widely used when developing Android applications, it’s also the recommended approach to creating an application.
The following diagram displays a generic mobile application architecture on Android.
What we can take from this diagram is the following:
Our Activity/Fragment may or may not have one, or multiple instances of different ViewModels, each view model has a dependency to…