SOCKET PROGRAMMING
A socket is a communications connection point (endpoint) that you can name and address in a network. Socket programming shows how to use socket APIs to establish communication links between remote and local processes. Is a way of connecting two nodes on a network to communicate with each other. One socket(node) listens on a particular port at an IP, while the other socket reaches out to the other to form a connection. The server forms the listener socket while the client reaches out to the server.
All servers use sockets, though not necessarily BSD sockets - BSD is a particular implementation of sockets, typically used in C-compatible compilers/frameworks, but it is not the only socket implementation that is available. Most programming languages provide some kind of socket framework.In socket programming in C, a socket can be created by the socket() function with syntax, int socket(int domain, int type, int protocol); The domain represents the address family over which the communication will be performed.
The domain is pre-fixed values present in the sys/socket.The socket is primarily a concept used in the transport layer of the Internet protocol suite or session layer of the OSI model.These data types might be named Location , Facility , Rack , Port or Card . If you are using the socket server as an interface between Netcool/Impact and a messaging system, you might define one data type for each type of message that is to be passed between the DSA and the socket server.
A socket is basically consistent of a source IP, source Port, destination IP and destination Port. (Physically, it really isn't anything, this is a software based concept) This way the operating system can tell which Application (through it's port number) needs to receive the packets or is sending out the packets.
Recommended by LinkedIn
SOCKET TYPES: