Statistics of on-line number of listeners

Implementation ideas The common process is that the standard mvc is the login form. The user submits the data to the login check. If the login check is passed, the session event will be triggered, saved and entered the online personnel list. The page will jump to the online user list. If the user logs out, it will be deleted from the online lis ...

Posted by Kurrel on Fri, 06 Dec 2019 00:03:33 -0800

Python - @property method changes properties

@property @property is a built-in decorator. It works the same way as ordinary decorators, except that the returned function is not a function, but a class object @Property is responsible for turning a method into a property to be called to ensure necessary checks on parameters. Property has three decorators: setter, getter, and deleter. Whe ...

Posted by p.persia69 on Thu, 05 Dec 2019 21:07:52 -0800

Independent access to alicloud IoT platform (Python) based on open source MQTT

By GXIC wongxmig Finish, welcome to follow IoT developer community. 1. Preparation 1.1 register alicloud account Use personal Taobao account or cell phone number to open the account of Ali cloud, and pass the real name authentication (can be certified by Alipay). 1.2 free IoT Suite Product official website https://www.aliyun.com/product/iot 1 ...

Posted by cemzafer on Thu, 05 Dec 2019 20:58:07 -0800

Source code implementation of Netty master slave Reactor multithreading mode

Netty -- source code implementation of master-slave Reactor multithreading mode Overview What is EventLoopGroup? EventLoopGroup is a container for storing EventLoop, and it should have the function of thread pool. graph BT; EventLoopGroup --> EventExecutorGroup; EventExecutorGroup --> ScheduledExecutorService; Because EventLoopGr ...

Posted by wmhop on Thu, 05 Dec 2019 20:44:52 -0800

Spring IOC Container Assembly Bean_XML-based Configuration

Develop required jar packages Four ways to instantiate beans 1. parameterless constructors (most commonly used) <?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema ...

Posted by timgolding on Thu, 05 Dec 2019 19:32:25 -0800

PostgreSQL source code interpretation (96) - partition table (3) (data insertion route (3) - get partition key)

This section describes the execpreparetuplerouting - > execfindpartition - > formpartitionkeydatum function, which gets the partition key value of Tuple. I. data structure ModifyTable Apply the rows generated by the subplan to the result table by inserting, updating, or deleting. /* ---------------- * ModifyTable node - * ...

Posted by Ryyo on Thu, 05 Dec 2019 19:19:20 -0800

Mybatis has its own connection pool for reading

1. Initialization of data source. The initialization entry is provided by SqlSessionFactoryBuilder.build(InputStream inputStream, String environment, Properties properties) method public SqlSessionFactory build(InputStream inputStream, String environment, Properties properties) { try { XMLConfigBuilder parser = new XMLConfigBuilder ...

Posted by kyme on Thu, 05 Dec 2019 17:10:44 -0800

Original 002 | take the spring boot transaction source code analysis special vehicle

Special vehicle introduction This special train is for Spring Boot transaction source code analysis Special vehicle problem Why can transaction be implemented with @ Transactional annotation? What can we learn after analyzing the transaction source code? Special vehicle terms affair In order to avoid dirty data, transactions are usually used ...

Posted by Zemnon on Thu, 05 Dec 2019 14:17:51 -0800

Detailed explanation of the up and down scrolling bulletin board of jQuery implementation

Before doing the project, I always wanted to make an up and down scroll bulletin board to display the latest announcement information of the website. At the beginning, I didn't have a clear idea. I found a lot of source code on the Internet, but I found that I couldn't satisfy myself. Some of them still had some small problems. For example, som ...

Posted by ngolehung84 on Thu, 05 Dec 2019 11:31:16 -0800

Django upload excel file

Install the module first pip3 install xlrd install xlrd package to parse table data Create the upload folder in the sub application statistics directory, Then go to settings.py To configure UPLOAD_ROOT = os.path.join(BASE_DIR,'upload') When there is an upload file in the form, the picture / form file can be submitted as follow ...

Posted by chris1 on Thu, 05 Dec 2019 08:24:45 -0800