fbpx
What is Asynchronous Messaging Design Pattern?

What is Asynchronous Messaging Design Pattern?

What is Asynchronous Messaging Design Pattern?

Previously we saw about What is Microservice? and the principles followed while developing MSA and the available design patterns. also, we saw an API Gateway design pattern.

Today we will see what is Asynchronous Messaging Design Pattern is.

What is Asynchronous Messaging Design Pattern?

Previously we saw about Chained or Chain of responsibility design pattern which makes the client wait for a long time, It also breaks the chain if any one service goes down and cause a bad experience for the clients.

To avoid such bad experiences for the client, The Asynchronous design pattern can be used, which communicate with the available services using message queue or event driven approach and not sequentially.

Yes, Messaging or events, The Asynchronous design pattern uses the Messaging Queue (MQ) or Event driven like ActiveMQ, RabbitMQ, Kafka and other tools for its communication with other services.

Example:

Consider we have Cart, Product, Stock, Order & Shipping services.

When the Product is added to the Cart, Stock must be updated accordingly, So the Product calls stock via Message Queue.

And then Order calls shipment via Message Queue to prepare a label for shipment.

This way the client need not wait for the flow of service to be completed to get the response immediately.

what is Asynchronous design pattern?

 

In the next article, we will see Shared Database or Shared Data design pattern.

 

LIKE | SHARE | SUBSCRIBE

WeCanCode-Author

WeCanCode-Author

November 11, 2021

Senior Developer | Java & C#.NET | 10++ years of IT experience.

Planning to learn ReactJS or Angular or Flutter.!

What is Chained or Chain of Responsibility Design Pattern

What is Chained or Chain of Responsibility Design Pattern

What is Chained or Chain of Responsibility Design Pattern

Previously we saw about What is Microservice? and the principles followed while developing MSA and the available design patterns. also, we saw an API Gateway design pattern.

Today we will see what is Chained or Chain of Responsibility Design Pattern is.

What is Chained or Chain of Responsibility Design Pattern?

The chained or Chain of responsibility pattern produces a single response which is a combination of multiple chained responses.

Example:

Consider we have Contact, Student & Fees three microservices, each web service communicates with the following or next service as in waterfall.

Yes, Contact service calls Student service and Student service calls Fees service. Response of Fees and Student will be returned back to Contact service.

What is Chained or Chain of Responsibility Design Pattern

Chained Or Chain Of Responsibility Design Pattern in Microservice

Here the Client must wait till the response comes back after the consolidated response is available, meaning the Client will be waiting for the chain of response to be returned back as a response.

Use this service where the client is not expecting any response. (Something like calling a batch job, synchronous tasks or orchestrated flow of actions.

All these services use the HTTP request or response for communicating,

Note: Each service request and response looks different from the chained flow.

 

In the next article, we will see Asynchronous Messaging design pattern.

 

LIKE | SHARE | SUBSCRIBE

WeCanCode-Author

WeCanCode-Author

November 07, 2021

Senior Developer | Java & C#.NET | 10++ years of IT experience.

Planning to learn ReactJS or Angular or Flutter.!

Add Image to Android app

Add Image to Android app

Add PNG Icon to Android app

 

In this article, let discuss on

Add PNG Icon to Android app

Let us see how to Add PNG icon to Android App. In the end you your app will use the icon you have added for the android application.

 In this article I’m going to use the existing android project created as part of this article Make WordPress as Android App. This Follow the code repo used  ).

How to Add PNG Icon to Android App?

You can add Image assets by Right click on the location where the image or icon need to be placed.

See below screenshot for the Menu option in Android Studio.

  • After right-click drawable folder, Choose New > Image Assets
  • You need to choose the image or icon from the browse menu under Source Asset section of Foreground Layer Tab.
  • Adjust the Scaling according to the image or icon output.
  • Go to Background Layer tab and adjust the background color or image accordingly.
  • Once done, click Finish (Note: Try to keep the same name as the previous icon file name, if you are replacing the icon)
  • Run the App to see the new Icon changed.
intellij add image asset menu
WeCanCode-Author

WeCanCode-Author

October 22, 2021

Senior Developer | Java & C#.NET | 10++ years of IT experience.

Planning to learn ReactJS or Angular or Flutter.!

Make WordPress as Android App

Make WordPress as Android App

Make WordPress as Android App

In this article, let discuss on

Make WordPress as Android App

Make WordPress as Android App. Yes, follow the article from top to bottom and do not miss out anything. In the end you will see your website or WordPress blog in Android phone as an application.

You can also publish the app in Google Play Store or any eco-system for Android apps (Such as Amazon app store, Samsung galaxy app store, Honor/Huawei App Gallery and So on).

How to Make WordPress as Android App?

Converting WordPress blog or Website is easy if you have hands-on with Android Studio and Android SDKs.

               Yes, you need to know little bit of java coding knowledge and basics of Android application development. Do not worry if you have very little knowledge on these both should also be fine. If you follow this article carefully.

WeCanCode-Author

WeCanCode-Author

October 20, 2021

Senior Developer | Java & C#.NET | 10++ years of IT experience.

Planning to learn ReactJS or Angular or Flutter.!

Microsoft Windows Emoji keyboard shortcut

Microsoft Windows Emoji keyboard shortcut

Microsoft Windows Emoji keyboard shortcut Win + .

In this article, let discuss on

Microsoft Windows Emoji keyboard shortcut Win + .

Emoji’s 😊😂🤣😍😒👌😘💕😁👍🙌

Emoji’s plays vital role in everyone’s life now!

We express our thoughts usings these Emoji’s. Emojis were part of Phone and Handheld devices. Due to heavy usage of these Emoji now PCs and Laptops also needed those emojies.

For very long I used to search the emoji in Google and copy paste them where ever needed, But  Winodws has this Emoji pop-up integrated.

Keyboard Shortcut for Emoji in Windows

  • During text entry, type Windows logo key   + . (period). The emoji keyboard will appear.
  • Select an emoji with the mouse, or keep typing to search through the available emojis for one you like.

    By Pressing Windows + . (period) will bring up the Emoji popup (as shown below)

    Microsoft Windows Emoji keyboard shortcut

    Wanna try it now 👓

     


    🚩Pro Tip: Type all the symbols like a pro

    Sometimes you need to type a character that isn’t on your keyboard, like an em-dash (—) or the copyright symbol (©). If you have a numeric keypad on your keyboard, you don’t have to find one and copy and paste, you can just do it! Here’s how:

    1. Hold down the Alt key on your keyboard.
    2. With the Alt key held down, type the four-digit code on the numeric keypad for the character you want. (Include the leading 0 if that’s required.)

      Note: This only works on the numeric keypad. This won’t work on the row of numbers at the top of the keyboard.

    3. Release the Alt key.

    Here’s just a few of the characters you can type with the Alt key:

    Symbol

    Name

    Alt-code

    ©

    Copyright symbol

    Alt+0169

    ®

    Registered symbol

    Alt+0174

    Trademark

    Alt+0153

    List Dot

    Alt+0149

    §

    Section symbol

    Alt+0167

    Dagger

    Alt+0134

    Double dagger

    Alt+0135

    en-dash

    Alt+0150

    em-dash

    Alt+0151

    Paragraph symbol (Pilcrow)

    Alt+0182

    ¡

    Upside-down exclamation mark

    Alt+0161

    ¿

    Upside-down question mark

    Alt+0191

    ¢

    Cent sign

    Alt+0162

    £

    British Pound

    Alt+0163

    Є

    Euro currency

    Alt+0128

    ¥

    Japanese Yen

    Alt+0165

    WeCanCode-Author

    WeCanCode-Author

    August 08, 2021

    Java & C#.NET Developer with 10++ years of IT experience.

    Planning to learn ReactJS or Angular or Flutter.!

    Searching a text in a file using grep

    Here we’re going to searching a text in a file using grep?

    Searching a text in a file using grep, this command will be very much handy when searching in multiple files or folders in unix terminal.

    grep is one of the powerful command used for searching in files or folder with the search pattern.

    Searching for text in file using grep

    Lets see how to search for text or string in files or folders using grep command

    Command Usage:
    grep [options] "search pattern"[regex] [filename/foldername]
    Note: use double quotes for your search string

    Options : (Below are frequently used options with grep command)
    -i Ignores case
    -n Print the line number
    -c Count of matched pattern (Will not print the search line, rather it just prints the count)
    -r Will search folders for matching text.
    -v non-matched lines are printed

    Try for yourself:

    1) Search for any string and print count
    hint: use -c
    2) Search entire folder for match pattern with , (This is special symbol)
    hint: “\,”
    3) Search string by ignoring the case and also search for multiple string in a file
    hint: use -v and in search string you need to split using | for multiple search string.

    Try for yourself and comment it here https://youtu.be/9pUPUEvJop8

    practice to keep FAMILIAR with the commands.

    Subscribe to our channel for more videos : https://bit.ly/aryanz-youtube

    https://youtu.be/9pUPUEvJop8
    Searching a text in a file using grep
    ~3Minutes: Tutorial

    Pin It on Pinterest