Removing Timezone from XMLGregorianCalendar

11 months ago codedestine 0
If you had worked on a project which consume or publish web services, then you would have faced a problem with date (XMLGregorianCalendar) object, where you would like to send only date string as yyyy-MM-dd but complete yyyy-MM-dd’T’HH:mm:ss’Z’ has been sent. This date string contains date, time and timezone information, if you like to send Read More

RabbitMQ Exchange Types, Bindings and Routing Keys

1 year ago codedestine 0
Exchanges are message routing agents, which are defined per virtual host within the rabbitMQ system. When program/application (Known as Producer) connect to RabbitMQ server to publish a message, it first sends the message to an exchange. After receiving a message, exchange routes them to different message queues with help of header attributes, bindings, and routing keys. It should be noted that messages Read More

RabbitMQ – Headers Exchange

1 year ago codedestine 0
Headers Exchange :- A headers exchange is an exchange which route messages to queues based on message header values instead of routing key. Producer adds some values in a form of key-value pair in message header and sends it to headers exchange. After receiving a message, exchange try to match all or any (based on the value of Read More

RabbitMQ – Topic Exchange

1 year ago codedestine 0
Topic Exchange :- A topic exchange is an exchange which route messages to queues based on the wildcard match between routing key and routing pattern specified during the binding of the queue. Producer adds routing key in message header and sends it to topic exchange. After receiving a message, exchange try to match the routing key with the binding routing pattern of Read More

RabbitMQ – Direct Exchange

1 year ago codedestine 0
Direct Exchange :- A direct exchange is an exchange which route messages to queues based on message routing key. The routing key is a message attribute in the message header added by the producer.Producer adds routing key in message header and sends it to direct exchange. After receiving a message, exchange try to match the routing key with the binding Read More

RabbitMQ – Fanout Exchange

1 year ago codedestine 0
Fanout Exchange :- A fanout exchange is an exchange which routes the received message to all the queues bound to it. When the producer sends the message to fanout exchange, it copies the message and routes to all the queues that are bound to it. It just ignores the routing key or any pattern matching provided Read More

Gold Bar Puzzle (Interview Puzzle)

1 year ago codedestine 0
Gold Bar Puzzle :- You have hired a person for seven days to work on your house and you have agreed to pay him a gold bar as a compensation. The gold bar is divided into seven pieces and is connected with each other like a chain. You have to give him a piece of Read More

10 Coins Puzzle (Interview Puzzle)

1 year ago codedestine 0
10 Coins Puzzle :- There are 10 coins placed on the table, 5 coins head up and 5 coins tails up. You are blindfolded and are allowed to touch the coins but you can’t tell which one heads up or tails up just by feeling and you can flip the coins any number of times. Read More

3 Mislabeled Boxes Puzzle (Interview Puzzle)

1 year ago codedestine 0
3 Mislabeled Boxes Puzzle :- You have given 3 boxes, One contains the red color ball, another contains the blue color ball and the third one contains the green color ball. All boxes are mislabeled, which means blue label box does not contain the blue color ball, red label box does not contain the red Read More

Heaven or Hell Puzzle (Interview Puzzle)

1 year ago codedestine 0
Heaven or Hell Puzzle :- You are standing before two doors. One leads to heaven and the other one leads to hell. There are two guardians, one by each door. You know one of them always tells the truth and the other always lies, but you don’t know who is the honest one and who Read More