Image for post
Image for post

At the beginning of October Oracle simplified obtaining of Java certification — instead of two exams now it is necessary to pass one, while the price for the exam has not changed. Who is interested in the level of tasks and more details about the exam, I will describe why I decided to pass, how I prepared, what questions were, and what conclusions I made.

In October I saw the news that Oracle is launching a new exam 1z0–819 instead of the previous 1z0–815 and 1z0–816. Previously, in order to become Oracle Certified Professional, you had to pass two exams and spend a total of $500. Now the amount has been reduced by half. In addition, the number of questions has changed, if earlier each exam had 80 questions and 150 minutes, now the exam lasts 90 minutes and there are 50 questions covering all topics from previous exams. …


Image for post
Image for post

There is often little time for safety during development, but it is a very important issue. In this series of articles, I will try to describe as simply as possible the main technologies to make your application secure.

In this article we will talk about OAuth. It is an older standard of user authorization, but still very popular in modern internet microservice architecture. Where do we start?

So, what is OAuth? It is a protocol that allows users to delegate their permissions from one service to others. Why is it needed? Could we live without this technology?

For example, say that you want to collect all emails from multiple services and accounts. You would give this service your login and password from all other services. You can do this, but is it safe? One service has all your login names and passwords from all your accounts. Your data will be stored explicitly. It is extremely unsafe, and your data could be compromised. …


We often need some simple and reliable instruments to parse data into POJO. Let’s write such an utility package for our projects.

First of all, we need a base object — Parser. What is his area of responsibility? It should have a public method that returns the desired entity. We need to parametrize this method because we want to get the final object. our raw entity supplier also needs to handle generic objects. Afterward, our Parser may look like:

Image for post
Image for post
public class Parser<T> {
public T getBean() {…}
}

This seems to be good. Let’s dive deep into this method. Our aim is to get some raw data and then map it into the desired class. Let’s assume we need to parse a CSV file. First of all, we need to read a line, then separate it by commas and transform this array of data into our…


A few days ago Spring Boot version 2.3.0.M1 was released. In the first string of the release notes, you can find project CNB mentioned, which is an attempt to simplify developer burden. It can automize build from source code. This is because, in my current project, we use microservices, but in the future, we will move to docker. CNB allows the developer to avoid writing and maintaining docker files.

Image for post
Image for post

The developer needs only one command to build a docker image.

Also, CNB supports a lot of interesting and useful technologies, like OCI support, modular structure, and layer caching availability. …


Image for post
Image for post

Hello, everybody! In this short article, I want to describe how you can create a simple bean validator with the annotation processor.

Let’s start. In each application we have beans. And in most cases those beans have restrictions on fields. And we want to have a simple instrument to work with them. We have several solutions: for example, we can validate fields inside our bean — in a constructor or setters. Or we can create a builder for this class and perform all the checks inside it. But if you have a simple check, for example, to check for null values in each field, you will need to write a lot of boilerplate code for the cases mentioned above. …


Image for post
Image for post

Hello, everybody! In this short article, I want to describe how you can create a filter with the Spring Cloud Gateway framework.

Let’s start. We have a problem: in our company we use microservice architecture. So, we have service discovery and a cloud gateway that are based on Spring technologies and more than one hundred microservices. Each developer has his own area of responsibility — each using a few microservices.

When I want to test my new version of microservice in a developer environment with connections to other services via a gateway, I need to forward all requests from my machine to my service. Let me explain: there are two microservices, named “UI”, one on my computer and the other in our network. Also, I have another microservice on my machine called “AUTH,” which uses Gateway to send requests to “UI.” But I want to communicate only with my instance, I don’t need a round-robin calling of “UI” services. …

About

Roman Ivanov

Passionate about Java and quantum mechanic

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store