Menu

How to change default port for Spring boot

Default port for Spring boot application is 8080, what if someone want to run their application other than port 8080 or other than default port. Where we need to put the port setting in project, so instead of default port 8080 Spring boot application start on port which we configure.

By Default Spring boot run on port 8080 and no where in your project you will find the port setting, if you just started a new Spring boot project. If you want to change the default port then you have to add the port setting in your project.

Where to put the port setting?

We need to add port setting in projects application.properties file. You will find this properties file under project directory > src > main > resources > application.properties

open application.properties file and add a new property server.port followed by port number. below is the example.
server.port = 8020

Nested if else in Bash Shell scripting

Today in this tutorial we will see how to write if else and nested if else in Bash Shell scripting.


 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Program in Bash Shell

CHECK_SOURCE="[main] INFO com.dobe.jcr.checknode.existence.App - Node  exists"

echo $CHECK_SOURCE | grep -w -o -i 'Node exists'

if [ $? == 0 ]; then

    echo " Node Exists"

    echo $CHECK_SOURCE | grep -w -o -i 'checknode'

    if [ $? == 0 ]; then

        echo "checknode exist"

        echo $CHECK_SOURCE | grep -w -o -i 'adobe'

            if [ $? == 0  ]; then

                echo "Adobe exist"

            else

                echo "Adobe doesnot Exist"

            fi

    else

        echo "checknode doesnot Exist"

    fi

else

    echo "Node doesnot Exists"

fi

You may download the raw from Gist: https://gist.github.com/RashidJorvee/9e9de5c6f8fd2303d0438b492ee9ad33

How to change the boarding station- IRCTC ticket

IRCTC portal has recently change their website look and feel. Earlier it was easy to select a different boarding station, if you are booking your ticket from station other than the boarding station. Some people are assuming this feature has been removed from http://irctc.co.in/ portal, but no, this service is still there just the appearance of the option has been changed.
There are two way to change the boarding station or boarding point of your journey.

1. While booking the ticket

When you select your itinerary and reach to fill the passenger information, on that same page right hand side along with journey information we have option to change the boarding station. You have to just click on the red text "Change Boarding Station?" and a new window will popup which will give you option to select your boarding point. Please refer the below screen shots. 
How to change boarding station IRCTC
How to change boarding station
Change Boarding Station option IRCTC
Change Boarding Station option IRCTC
choose your new boarding station IRCTC
choose your new boarding station

2. After ticket booking has been confirmed

After successfully bokking your ticket you may also change your boarding point or boarding station. To do so, go to my account >> my transactions >> booked ticket history select or click on the ticket for which you  wants to change the boarding point. Now click on Change boarding point option at the bottom of the ticket. Below is the screen shot for reference.
Change boarding point for a booked ticket. IRCTC
Change boarding point for a booked ticket.