Spring boot + websocket + netty to push messages
Thank you for your reference- http://bjbsair.com/2020-04-01/tech-info/18392.html
One of the application scenarios of Netty in the project: the message push function can be used to push messages to all users, or to specify a user. The spring boot project is created. The background server uses Netty technology, and the front page uses WebSocket t ...
Posted by jpadie on Thu, 02 Apr 2020 08:24:30 -0700
Vue cli simple use of axios and cross domain development environment
Official: Axios is a promise based HTTP library that can be used in browsers and node.js
Here is English document And found on kancloud Chinese document
Install under the vue project (here is a simple example of using the project created by vue CLI)
$ npm i axios
Enter src/main.js to import axios
import axios f ...
Posted by misterph on Thu, 02 Apr 2020 06:17:36 -0700
Angular Js pagination display data
We often use paging to display data when we do projects. The principle is very simple: each time we click (next / last) a page, we send a request to the background to obtain relevant JSON data. What I'm demonstrating here is that every time I request, I will pass two parameters (pageSize – data to be displayed on ...
Posted by cash09 on Thu, 02 Apr 2020 05:40:15 -0700
Spring boot auto assembly principle
SpringBootApplication annotation
@Target(ElementType.TYPE)
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Inherited
@SpringBootConfiguration
@EnableAutoConfiguration
@ComponentScan(excludeFilters = { @Filter(type = FilterType.CUSTOM, classes = TypeExcludeFilter.class),
@Filter(type = FilterType.CUSTOM, classes = AutoConfigu ...
Posted by theprofession on Thu, 02 Apr 2020 01:45:43 -0700
Automatic deployment tool syncd
1, Deployment installation
(1) Common installation methods
1. curl https://syncd.cc/install.sh | bash
2. dockerfile installation mode is under test
(2) Installation references
1.https://syncd.cc/docs/#/install
2.https: //github.com/dreamans/syncd
3.https: //gitee.com/dreamans/syncd
2, Specification for use
(I) service address
1. ...
Posted by Psycho on Wed, 01 Apr 2020 19:49:38 -0700
Solution to get httpsession in spring webSocket
If you don't know the basic usage of spring webSocket, please refer to: webSocket implementation of code scanning login
Handshake Interceptor: the implementation class of HttpSessionHandshakeInterceptor overrides the beforeHandshake method, as follows
@Override
public boolean beforeHandshake(ServerHttpRequest request, ServerHttpResponse res ...
Posted by ejaboneta on Wed, 01 Apr 2020 16:45:10 -0700
Using Express to build Node.js server
Express: a fast, open and simple web development framework based on Node.js platform.
Explain
install
Build Express
Test success
Call server method: Vue Resource & Axios
The difference between Vue resource and axios
axios reference: https://www.awesomes.cn/repo/axios/axios
Installation:
Third party npm is used here
Install express ...
Posted by mattyj10 on Wed, 01 Apr 2020 11:04:38 -0700
Cross domain solution 1: JSONP
Homologous strategy
Balabalabala (the definition doesn't need to be mentioned, simply speaking, the protocol, port and domain name should be the same.)
Note: the difference caused by protocol and port is not within the scope of front-end solution
JSONP
The principle of jsonp is very simple. It is to create s ...
Posted by tommy1987 on Wed, 01 Apr 2020 08:33:59 -0700
[daily] Go language Bible -- JSON exercise 2
Exercise 4.12: the popular web comic service xkcd also provides a JSON interface. For example, an https://xkcd.com/571/info.0.json request will return a detailed description of the 571 number that many people love. Download each link (only once) and create an offline index. Write an xkcd tool that uses these offline indexes to print the URL ...
Posted by vigour on Wed, 01 Apr 2020 07:44:17 -0700
JAVA simple parsing json file
JAVA simple parsing json file
First, put the json file I want to parse:
{ "resultcode":"200", "reason":"Success", "result":{ "data":[ { "id":"14", "title":"Pork braised in brown sauce", "tags":"Home Dishes;Aged;salty;Semih.-1 hour;Teenagers;white collar;Braise in soy sauce;1-2 people;Wok", "imtro":"With quail eggs, I wish you all a happy new y ...
Posted by jdorma0 on Wed, 01 Apr 2020 07:14:25 -0700