bind function of UDP sender in c/c + + network programming

bind function of UDP sender in network programming The effect of calling bind function on the sender of upd: assign socket to a specific port. If bind is not called, the kernel will randomly assign a port. The purpose of the upd sender calling the bind function: if there are two senders and the receiver needs to identify which sender is co ...

Posted by andym01480 on Mon, 16 Dec 2019 08:06:36 -0800

Kafka ou 2.12-2.0.0 installation process

1. Download Kafka? 2.12-2.0.0.tgz and upload it to / usr/local/kafka / Extract and remove the installation package 2. configuration Modify the config/server.properties of each server cd /usr/local/kafka/kafka_2.12-2.0.0/config vim server.properties Modify several places:broker.id : unique, fill in the number, 10,11,12,13,1 ...

Posted by N350CA on Sun, 15 Dec 2019 12:29:42 -0800

TCP based calculator (Java)

A calculator based on TCP communication, the client sends data to the server through the button, the server calculates and processes the data, and sends the calculation result back to the client. It uses multithreading to enable. Server thread: package com.netproject2; import java.io.DataInputStream; import java.io.DataOutputStr ...

Posted by JAM on Fri, 13 Dec 2019 12:19:39 -0800

workerman message push

workerman's message push Linux system environment detection Linux system can use the following script to test whether the native PHP environment meets the requirements of WorkerMan. curl -Ss http://www.workerman.net/check.php | php If all the above scripts show ok, it means that the requirements of WorkerMan are met Download of We ...

Posted by morgann7 on Fri, 13 Dec 2019 11:58:22 -0800

Initial knowledge of python Network programming-01

Recently learning the basic knowledge of python, I find it interesting to go to the network programming section. Write a blog to record, first you can know the basic knowledge of computer network, just refer to relevant books, this article only makes a simple introduction! 1.OSI seven-layer protocol, TCP, UDP protocol First of all, the comput ...

Posted by jdbfitz on Tue, 10 Dec 2019 23:53:30 -0800

Boost.Asio source reading: services and asynchronous operations

Based on Boost 1.69, this article cuts out some deprecated or different configured code blocks that are not related to the topic of this article when displaying the source code. Service type resolving service socket/file operation timer ... service resolution Here, take the reactive socket service that provides services around reactor as an e ...

Posted by phpforever on Tue, 10 Dec 2019 11:49:23 -0800

Redis source reading notes - server startup and initialization

Start of server The main function of Redis server is in server.c. // server.c int main(int argc, char **argv) { struct timeval tv; int j; /* Set some constants of the server */ /* We need to initialize our libraries, and the server configuration. */ #ifdef INIT_SETPROCTITLE_REPLACEMENT spt_init(argc, argv); #endif setl ...

Posted by jeff_papciak on Tue, 10 Dec 2019 00:11:57 -0800

A comparative analysis of golang socket and Linux socket

After posix standard was introduced, socket has been well supported on all major OS platforms. Golang is a cross platform programming language with runtime. The socket API provided to developers in Go is based on the native socket interface of the operating system. But the behavior of socket interface in golang is different from that of native ...

Posted by art15 on Mon, 09 Dec 2019 18:41:31 -0800

Using IDisposable interface to build unmanaged resource objects

Managed and unmanaged resources In. Net, there are two kinds of resources used by objects: managed resources and unmanaged resources. Managed resources are managed by CLR and do not need to be controlled manually by developers. Managed resources in. Net mainly refer to "memory of objects in the heap"; unmanaged resources refer to some ...

Posted by knowram on Mon, 09 Dec 2019 09:50:30 -0800

Database -- one master and many slaves

Multiple real columns and one principal and many subordinate Create a directory for database information [root@db200 ~]# mkdir /data/330{7..9} –p Create a file to hold the profile [root@db01 ~]# touch /data/330{7..9}/my.cnf Edit 3307 profile [root@db01 ~]# vim /data/3307/my.cnf [mysqld] basedir=/application/mysql datadir=/data/3307/data so ...

Posted by oaskedal on Sun, 08 Dec 2019 18:19:17 -0800