zookeeper native api operation

/** * TODO: * @package: com.zzhijian.zookeeperdemo.zk * @date: 2019-08-15 10:57 **/ @Slf4j public class ZookeeperDemo { private static String ZK_ADDRESS = "zkServer:2181,zkServer:2182,zkServer:2183"; public static void main(String[] args) { try { ZooKeeper zooKeeper = ge ...

Posted by boardy on Wed, 02 Oct 2019 00:20:06 -0700

Python Rapidly Develops Scrapy, a Distributed Search Engine - Reptilian Data Preservation

Note: Data saving operations are performed in pipelines.py files Save the data as a json file spider is a signal detection # -*- coding: utf-8 -*- # Define your item pipelines here # # Don't forget to add your pipeline to the ITEM_PIPELINES setting # See: http://doc.scrapy.org/en/latest/topics/item-pipeline.html from scrapy.pipelines.images i ...

Posted by minorgod on Tue, 01 Oct 2019 21:35:23 -0700

xlnet Chinese text classification task

xlnet Chinese version of the pre training model has finally come out, see the address. https://github.com/ymcui/Chinese-PreTrained-XLNet After coming out, we tried the Chinese text categorization model. The xlnet model has changed many things compared with Bert. The model level is not much. The curre ...

Posted by kashmirekat on Tue, 01 Oct 2019 09:03:56 -0700

sqlalchemy related operations (ORM)

Environment: Python 3.7, pycharm ORM(Object-Relational-Mapper) Object Relational Mapping (ORM) is a technology that allows you to query and manipulate data from a database using object-oriented paradigms. sqlalchemy is one of the libraries (frameworks) that implement ORM technology. advantage Simplify development because it automatically perfo ...

Posted by ppowell on Mon, 30 Sep 2019 22:09:17 -0700

The use of websocket in spring boot + Vue

1. An Implementation of websocket in springboot In the java background, websocket is configured as a server-side configuration, which is as follows @Configuration public class WebSocketConfig {    @Bean(name="serverEndpointExporter") public ServerEndpointExporter getServerEndpointExporterBean(){ return new ServerEndpo ...

Posted by The Wise One on Mon, 30 Sep 2019 16:40:52 -0700

Hive custom UDF function

In hive, sometimes you need to customize some functions according to business requirements. Here are the steps to customize functions 1. Create a new maven project and introduce dependencies in the project's pom file <dependency> <groupId>org.apache.hive</groupId&g ...

Posted by ded on Mon, 30 Sep 2019 03:59:50 -0700

Crawler Pass: GlidedSky Foundation Question

Website: http://glidedsky.com Topic 1: Calculating the sum of all the numbers on the web page Register in and see Click in the website to be crawled and find that it's all digital, the first question is really simple, there's nothing to talk about. Question 2: Same question, 1000 requests This problem is the same, the simplest is to change t ...

Posted by tronicsmasta on Mon, 30 Sep 2019 03:19:17 -0700

Falsk Framework Session and Flask-Session

Catalog Cookie and Session Session storage mechanism in Falsk Related Configurations Use the Flask-Session tripartite component Basic exercises Cookie and Session Cookie:#Storage size is limited, stored on the client, there is a security risk Cookies, meaning cookies, were proposed ...

Posted by megaalf on Thu, 26 Sep 2019 20:08:32 -0700

Spring Boot 2 is configured using Servlet, Listener, and Filter

Development Environment: IntelliJ IDEA 2019.2.2Spring Boot Version: 2.1.8 Create a new SpringBoot project named demo. 1. Configuring with Servlet s 1. Modify the code for the startup class DemoApplication.cs and add the annotation ServletComponentScan, which scans for Servlet components, including using @WebServlet, Classes decorated with @ ...

Posted by Awanka on Tue, 24 Sep 2019 09:59:45 -0700

What is Browser Object BOM?

What is BOM? BOM (Browser Object Model) is a browser object model that provides content-independent objects that interact with browser windows. Because BOM is mainly used to manage the communication between windows, the core object of BOM is window. Relevant methods (attributes) Popup window.alert() Properties of URL s // Current HTML URL locat ...

Posted by bimo on Tue, 24 Sep 2019 03:25:15 -0700