IBM Cloud – API Connect – Developer Portal Usage

I have already mentioned many details about IBM API Connect service in this post https://kenanhancer.com/2019/06/30/ibm-cloud-api-connect/ But, I tried to emphasize some details more clearly. There is a sequential structure in IBM API Connect. That is Cloud Foundry Organisations => Spaces => Catalogs => Products => APIs. In this case, if we want to find any API, we need to know Cloud Foundry Org, Space, Catalog, Product respectively so that we can find our API.

Cloud Foundry Orgs

Cloud Foundry Orgs can be find under Account and Cloud Foundry orgs menu as shown below screenshot. In my case, I have 4 Cloud Foundry Orgs. As I said preceding, there is spaces under Organisations. So, there is 1 space in APIGateway-dev organisation and 2 spaces in kenanhancer@hotmail.com organisation. APIGateway-dev2 and APIGateway-dev3 don’t have any spaces.

So, let’s see APIGateway-dev org details in the following screenshot.

This screenshot shows APIGateway-dev Users. There is also Space Users.
There is only one user in red space. This means that we nee give access any user organisation level first and later space level. Let say we have dev, test, preprod and prod spaces. We can give access to developers only for dev and test not for preprod and prod so that APIs can be deployed by deployment team.
Continue reading

Java – Difference between equals() method and == operator

“==” operator compares 2 objects memory reference. Now, lets have a look at the simple example below:

Example 1:

String str1 = “test”;

String str2 = “test”;

if (str1 == str2) {
System.out.println(“str1 == str2 is TRUE”);
} else {
System.out.println(“str1 == str2 is FALSE”);
}

Output:

str1 == str2 is TRUE

Example 2:

String str1 = new String(“test”);

String str2 = new String(“test”);

if (str1 == str2) {
System.out.println(“str1 == str2 is TRUE”);
} else {
System.out.println(“str1 == str2 is FALSE”);
}

Output:

str1 == str2 is FALSE

In the code above, Outputs of Example 1 and Example 2 are different. Because, when you create String, JVM searches that literal in String pool, if it matches, same reference will be given to that new String. So, Example 1 output is TRUE.

In Example 2, the output is FALSE. Because, 2 objects refer to different memory location.

Continue reading

Creating Simple Web Project Using Nodejs, Gulp, CoffeeScript, SASS, Less, Stylus, Jade, Haml, Express Framework etc.

This article purpose is to create a web project using some popular technologies. So, after read this article, you will be informed how you can use these technologies together. (Nodejs, Gulp, CoffeeScript, SASS/SCSS, Less, Stylus, Jade, Haml, Express Web Framework, etc.). Maybe you will change point of view and start to discover more.

Firstly, I think that we should have a package manager. So, I will use Chocolatey in Windows. If you don’t have in your computer, you can read http://kenanhancer.com/2016/10/27/chocolatey-package-manager-for-windows/

Continue reading