• Ajax asynchronous load resolution


    Ajax (asynchronous JavaScript and XML, asynchronous JavaScript and XML). It is not a new programming language, but a new method using the existing standards. It is the art of exchanging data with the server and updating some web pages without reloading the whole page.So let’s go into the world of Ajax. Basic grammar Before learning […]

  • Asynchronous redis queue for data warehousing


    Business requirements The app client sends the JSON data to the server interface once a day, clears the cache, and then sends it again Business logic before the problem: The PHP interface first converts JSON into an array to insert non-existent data into a large table The user’s existing and new ID Enter another detail […]

  • Swoole 2019: reduce complexity to simplicity and break cocoons to butterflies


    SwooleOpen source projects from2012The first version has been released since7Years of history. In these seven years: Submitted8821Secondary code change Released287Versions Received and resolved1161secondissuefeedback Amalgamated603secondpull request Share100Developer contribution code stayGitHubHarvest11940Star Association 2018We launched a newSwoole4Version, beforeSwooleThe main programming mode is synchronous blocking mode or asynchronous callback. New implementation based on CO processCSPProgramming is becoming usOnlyRecommended programming […]

  • JSP page list shows the asynchronous implementation of Ajax


    1. The server first returns to the basic structure of the page (such as message. JSP), <%@ page language=”java” contentType=”text/html; charset=utf-8″ pageEncoding=”utf-8″%> <%@ taglib prefix=”c” uri=”http://java.sun.com/jsp/jstl/core” %> <%@ taglib prefix=”fmt” uri=”http://java.sun.com/jsp/jstl/fmt”%> <% String path = request.getContextPath(); String basePath = request.getScheme() + “://” + request.getServerName() + “:” + request.getServerPort() + path + “/”; %> <!DOCTYPE html> […]

  • Getting started with Ajax


    What is Ajax? Ajax means asynchronous JavaScript and XML. In short, it is a scripting language that uses XMLHttpRequest objects to communicate with the server side. It can send and receive information in various formats, including JSON, XML, HTML and text files. The most attractive feature of AJAX is its “asynchronous” feature, which means that […]

  • Brief introduction to Ajax


    Ajax (asynchronous JavaScript and XML: “asynchronous JavaScript and XML”) Ajax has become a commonplace topic. It originated in 1997. Microsoft invented the key technology and Google promoted it. Why is Google? This is another sad story. In fact, Microsoft started to support xmlhttprequse object when it successfully launched IE5 in 1995. Unfortunately, Microsoft executives did […]

  • This article may be the only difference between you and understanding promise (1)


    Let me see~ Before promise: Because the JS engine allocates only one thread to execute JS code, JavaScript is single threaded. Because of this pre setting, one of the things that front-end Er can’t get around when writing code is how to deal with asynchrony, that is, how to deal with the “now and later” […]

  • Lua web quick development guide (9) – using CF’s built-in asynchronous Library


    API introduction CF framework provides built-in asynchronous LibrarycfWhen we need to use it, we must first import the API:local cf = require “cf”. Timer and cycle timer CF library built in some timer methods, these methods provide developers with the ability to control time eventscf.timeout、cf.at、cf.sleep. cf.sleepThe method is ablockThere is only one parameter to set […]

  • Developing a chat room based on websocket with spring boot integrated netty


    Preface Based on spring boot, with the help of netty to control long links, we use websocket protocol to make a real-time chat room. Project effectiveness Unified login path of the project: http: / / localhost: 8080 / chat / nettyUser name randomly generated, asynchronous method called offline, data write operation, log in and display […]

  • Front end asynchronous solution-3 (promise)


    I haven’t written for many days. I’ve been learning promise and generator intermittently these days. Today, I can finally combine the two things to solve the asynchronous problem. Today, I’d like to share the usage of promise and asynchronous processing with you.As always, we’d better simulate a promise first. //Coughing and coughing, that’s how it’s […]

  • Front end asynchronous solution-4.1 (generator)


    Preface Finally, I started to write the generator, which is a step closer to the end of this series. In fact, I’m still in a state where I can use the generator but don’t understand the principle, but it’s easy to forget if I don’t summarize the knowledge and record it, so I still record […]

  • Front end asynchronous solution-4.2 (Generator + Promise)


    Why the combination of generator and promise?Most of the articles on the Internet are for the sake of simpler handling of errors, but I haven’t realized this yet, but I think it’s almost the same. But let’s learn the usage first;Let’s start with a simple usage: //Simplest usage function request() { return new Promise(function (resolve, […]