KEMBAR78
Self Study Topics 1 | PDF | Internet Standards | Computer Architecture
0% found this document useful (0 votes)
14 views14 pages

Self Study Topics 1

The document provides an overview of various communication protocols including HTTP, HTTPS, AMQP, and XMPP. It details the functionalities, features, and operational principles of these protocols, emphasizing their roles in secure data transfer, message queuing, and real-time communication. Key aspects such as statelessness in HTTP, encryption in HTTPS, and interoperability in AMQP are highlighted, along with the structure and terminology used in these protocols.

Uploaded by

bataviyaharsh511
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views14 pages

Self Study Topics 1

The document provides an overview of various communication protocols including HTTP, HTTPS, AMQP, and XMPP. It details the functionalities, features, and operational principles of these protocols, emphasizing their roles in secure data transfer, message queuing, and real-time communication. Key aspects such as statelessness in HTTP, encryption in HTTPS, and interoperability in AMQP are highlighted, along with the structure and terminology used in these protocols.

Uploaded by

bataviyaharsh511
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

19-04-2025

HTTP
 HTTP is most widely used application layer protocol for communication over TCP/IP
 An HTTP connection enables a one-way communication at an instance from client API to a server or
from server to the API
 An HTTP client connects to an HTTP server using TCP and then the client sends a resource after
establishing an HTTP connection
 HTTP polling is a method for receiving new messages or updates from an HTTP server.
 An HTTP transfer is stateless which means each data transfer is an independent request. Therefore,
header overhead information and meta-data of previous state need to be present with each HTTP
request.
 Metadata is data which describes the data for interpretation in future.
 Each data interchange needs large headers over 100s of byte, and thus greater latency in request-
response exchanges.
 HTTP requests at short, regular intervals so that responses are nearly in real time
 Eight HTTP specific specified methods. The HTTP specific methods are as follows. 1. GET. 2. POST. 3.
HEAD. 4. CONNECT. 5. PUT. 6. DELETE. 7. TRACE. 8. OPTIONS. (Last four from 1.1.)

201
19-04-2025

HTTPS (Secure HTTP)


• This protocol allows transferring the data in an encrypted form.
• The HTTPS protocol is mainly used where we require to enter the login credentials.
• To provide encryption, HTTPS uses an encryption protocol known as Transport Layer
Security, and officially, it is referred to as a Secure Sockets Layer (SSL).
• This protocol uses a mechanism known as asymmetric public key infrastructure, and it
uses two different keys.
•Private key: This key is available on the web server, which is managed by the owner of a website. It decrypts the
information which is encrypted by the public key
•Public key: This key is available to everyone. It converts the data into an encrypted form.
•The SSL protocol encrypts the data which the client transmits to the server. If someone tries
to steal the information which is being communicated between the client and the server,
then he/she would not be able to understand due to the encryption.

202
19-04-2025

203
19-04-2025

Advanced Message Queuing Protocol


• AMQP is an open standard middleware at the application layer developed for message-oriented
operations.
• It tries to bring about the concept of interoperability between clients and the server by enabling
cross-vendor implementations.
• AMQP, creates a common ground which can be used for all message queuing and brokering
applications to work and interoperate.
• In AMQP, applications that send messages (known as publishers) post messages to AMQP brokers
that distribute them to applications that process messages (consumers).
• Both request–response and publish–subscribe methods are supported.
• AMQP is considered as a wire-level protocol.
• Here, the data format description is released on the network as a stream of bytes.
• This description allows AMQP to connect to anyone who can interpret and create messages in the
same format.
• It also results in a level of interoperability where anyone with compliant or supporting means can
make use of this protocol without any need for a specific programming language

209
19-04-2025

• AMQP is a binary wire protocol, which was designed for interoperability between different vendors.
Where other protocols have failed, AMQP adoption has been strong.
• Companies like JP Morgan use it to process one billion messages a day. NASA uses it for Nebula
cloud computing.
• Google uses it for complex event processing.
• It is used in one of the world’s largest biometric databases India’s Aadhar project—home to 1.2
billion identities.
• It is used in the ocean observatories initiative—an architecture that collects 8 terabytes of data per
day.
• AMQP is all about queues. It sends transactional messages between servers. As a message-centric
middleware that arose from the banking industry, it can process thousands of reliable queued
transactions.
• AMQP is focused on not losing messages. Any communications from the publishers to exchanges
and from queues to subscribers use TCP, which provides strictly reliable P2P connection. Further,
endpoints must acknowledge the acceptance of each message. The standard also describes an
optional transaction mode with a formal multiphase commit sequence.
• AMQP middleware focuses on tracking all messages and ensuring each is delivered as intended, regardless of failures or
reboots.

210
19-04-2025

AMQP Features
• AMQP is built for the underlying TCP and is designed to support a variety of
messaging applications efficiently.
• It provides a wide variety of features such as flow-controlled communication,
message-oriented communication, message delivery guarantees (at most once, at
least once, and exactly once), authentication support, and an optional SSL or TLS
based encryption support.
• The AMQP is specified across four layers: 1) type system, 2) process to process
asynchronous and symmetric message transfer protocol, 3) extensible message
format, and 4) set of extensible messaging capabilities.
• In continuation, the primary unit of data in AMQP is referred to as a frame. These
frames are responsible for the initiation of connections, termination of
connections, and control of messages between two peers using AMQP.

211
19-04-2025

212
19-04-2025

AMQP Assembly and Terminology


• Broker (Server): An application - Main AMQP Components
implementing the AMQP model - • The AMQP Model defining how messages
that accepts connections from are received, routed, stored, queued and
clients for message routing, queuing how application parts handling these tasks
etc work rely on the clear set definitions of the
• Message: Content of data below components:
transferred / routed including • Exchange: A part of the broker (i.e. server)
information such as payload and which receives messages and routes them
message attributes. to queues
• Consumer: An application which • Queue (message queue): A named entity which
receives message(s) - put by a messages are associated with and from where
producer - from queues. consumers receive them
• Producer: An application which put • Bindings: Rules for distributing messages from
messages to a queue via an exchanges to queues
exchange
213
19-04-2025

• The internal structure or an AMQP broker includes three types of entities:


exchanges, queues and bindings.
• Messages posted to a broker first go to an exchange. Then, the exchange will route
the message to a queue that is bound to the exchange using special rules called
bindings.
• Each exchange can have zero or more queues bound to it. Lastly, consumers will
receive the messages from the queue
• Message routing
Both bindings and messages contain strings called routing keys that the broker uses
to decide where to route the message.
The mode of routing messages from an exchange to a queue is based on the type of
the exchange. There are four types of exchanges:
Direct, Fanout,Topic,Headers

214
19-04-2025

There are nine frame types in AMQP:


(i) Open: responsible for opening the connection between peers.
(ii) Begin: responsible for setup and control of messaging sessions between peers.
(iii) Attach: responsible for link attachment.
(iv) Transfer: responsible for message transfer over the link.
(v) Flow: responsible for updating the flow control state.
(vi) Disposition: responsible for updating of transfer state.
(vii) Detach: responsible for detachment of link between two peers.
(viii) End: responsible for truncation of a session.
(ix) Close: responsible for closing/ending a connection

215
19-04-2025

Operational Principle
• A new link is initiated between peers that need to exchange messages by sending
an ATTACH frame. A DETACH frame terminates the link between peers.
• Unidirectional messages are sent using the TRANSFER frame once a link is
established.
• Every message transfer state has to be mutually settled by both the sender and the
receiver of the message. Any change in state and settlement of transfer is notified
using a DISPOSITION frame.
• A session can accommodate multiple links in both directions. Unlike the link, a
session is bidirectional and sequential.
• Upon initiation with a BEGIN frame, a session enables a conversation between
peers. The session is terminated using an END frame.
• Multiple logically independent sessions can be multiplexed between peers over a
connection. The OPEN frame initiates a connection and the connection is
terminated by using a CLOSE frame.

216
19-04-2025

XMPP
• The Extensible Messaging and Presence Protocol, or XMPP, which was initially named as
Jabber, is designed for message-oriented middlewares based on the extensible markup
language (XML).
• XMPP was developed for instant messaging, maintenance of contacts, and information
about network presence.
• Structured and extensible data between two networked nodes/devices can be exchanged
in near realtime using this protocol.
• XMPP has found use in VOIP (voice-over Internet protocol) presence signaling, video and
file transfers, smart grid, social networks, publish– subscribe systems, IoT applications, and
others.
• The protocol, being open-source, has enabled a spurt of developments in various freeware
as well as commercial messaging software.
• As XMPP follows a client–server architecture, peers in a network cannot talk directly to one
another through XMPP.
• All communication between peers has to be routed through an XMPP server. The XMPP
model is considered to be decentralized as anyone can host an XMPP server to which
217
various clients can subscribe.
19-04-2025

• A unique XMPP address, which is also


referred to as a Jabber ID (JID), is assigned
to every user on the network.
• The JID, similar to an email address, has a
username and a domain name
(user@domain.com).
• The domain name is mostly the IP address
of the server hosting the XMPP service.
XMPP allows its users to login from multiple
devices by means of specifying resources.
• The resource is used to identify a user’s
clients/devices (home, mobile, work, laptop,
and others), which is generally included in
the JID by appending the JID with the
resource name separated by a slash.

218
19-04-2025

• A typical JID looks like this: user@domain.com/resource. Resources are prioritized


using numerical IDs.
• Any message arriving at the default JID (without resource name) is forwarded to
the resource with the highest priority (largest numerical ID value). Often
• JIDs without usernames are used for specific control messages and system
messages, which are meant for the server.
• The use of JID in this mode—without an explicit IP address—allows XMPP to be
used as an overlay network on top of multiple underlay networks

219

You might also like