deal11's recent timeline updates
v2ex 新人报道
Sep 5, 2022
deal11's repos on GitHub
JavaScript · 1 watchers
medis
Medis is a beautiful, easy-to-use Mac database management application for Redis.
TypeScript · 0 watchers
analytics-react-native
The hassle-free way to add analytics to your React-Native app.
CSS · 0 watchers
basscss
Low-level CSS Toolkit
JavaScript · 0 watchers
compression
Node.js compression middleware
JavaScript · 0 watchers
dagre
Directed graph layout for JavaScript
0 watchers
dbt_ml
Package for dbt that allows users to train, audit and use BigQuery ML models.
0 watchers
debezium
Change data capture for a variety of databases. Please log issues at https://issues.redhat.com/browse/DBZ.
0 watchers
deploy-functions-with-the-sdk
Write a build-and-deploy script for Stedi Functions using the SDK.
Go · 0 watchers
fake-gcs-server
Google Cloud Storage emulator & testing library.
Python · 0 watchers
gcp-storage-emulator
Local emulator for Google Cloud Storage
CSS · 0 watchers
grid
responsive flexbox grid with inline-block legacy support
Java · 0 watchers
kafka-pubsub-emulator
Implementation of Google Cloud Pub/Sub backed by Apache Kafka.
JavaScript · 0 watchers
layer-ui-web
Layer UI Library for use with the WebSDK
JavaScript · 0 watchers
layer-websdk
Layer Web SDK is a JavaScript library for adding chat services to your web application
Swift · 0 watchers
Lightbox
:milky_way: A convenient and easy to use image viewer for your iOS app
TypeScript · 0 watchers
logger-js
Python · 0 watchers
mongo-connector
Data replication from MongoDB to MongoDB, Elasticsearch, Solr, and more!
Java · 0 watchers
mongo-java-driver
The Java driver for MongoDB
Java · 0 watchers
mongo-java-driver-reactivestreams
The Java Reactive Stream driver for MongoDB
C++ · 0 watchers
openconnect-gui
MOVED TO https://gitlab.com/openconnect/openconnect-gui
JavaScript · 0 watchers
postcss-containerize-media-queries
PostCSS plugin to safely convert CSS media queries to container queries
0 watchers
python-holidays
Generate and work with holidays in Python
0 watchers
react-aim
Determine the cursor aim for triggering mouse events.
JavaScript · 0 watchers
react-content-loader
:white_circle: SVG component to create placeholder loading, like Facebook cards loading.
JavaScript · 0 watchers
react-imgix
React component to display imgix images
Objective-C · 0 watchers
react-native-apple-authentication
React Native apple sign in
JavaScript · 0 watchers
react-places-autocomplete
A React component for Google Maps Places Autocomplete
JavaScript · 0 watchers
react-star-ratings
A customizable svg star rating component for selecting x stars or visualizing x stars
JavaScript · 0 watchers
react-waypoint
A React component to execute a function whenever you scroll to an element.
Java · 0 watchers
RxJava
RxJava – Reactive Extensions for the JVM – a library for composing asynchronous and event-based programs using observable sequences for the Java VM.
JavaScript · 0 watchers
split-javascript-client
NodeJS and Browser SDK client for Split Software
Java · 0 watchers
vertx-web
HTTP web applications for Vert.x
0 watchers
wiki-images
deal11

deal11

V2EX member #593465, joined on 2022-09-05 14:34:48 +08:00
deal11's recent replies
Sep 13, 2022
Replied to a topic by justanetizen 程序员 推荐一个不错的 Cplusplus 网络库
所谓系统级的异步 API, 目前已知:iocp 和 io_uring 吧
Sep 6, 2022
Replied to a topic by justanetizen 程序员 推荐一个不错的 Cplusplus 网络库
@deal11 看 yasio 的源码,正是使用的 select + nonblocking socket 多路 io 复用模型,select api 几乎可以跨所有操作系统平台。
Sep 6, 2022
Replied to a topic by justanetizen 程序员 推荐一个不错的 Cplusplus 网络库
我猜题主之所以关注到 yasio ,是因为该库 github 标题提到: "any client applications"
Sep 6, 2022
Replied to a topic by justanetizen 程序员 推荐一个不错的 Cplusplus 网络库
@deal11 YOPT_S_NO_NEW_THREAD
Sep 6, 2022
Replied to a topic by justanetizen 程序员 推荐一个不错的 Cplusplus 网络库
O_NONBLOCK + std::thread 算不上“不错”,这句话有误导。任何程序都离不开线程,libuv,asio 等离开 thread 也啥都干不了,任何进程至少有一个线程不是。std::thread 只是一种封装接口。看 yasio 文档,可以通过 YOPT_S_NO_THREAD 禁用内部创建线程,这样,所有网络消息和事件都在 io_service.run 调用者线程执行,至于这个线程是进程主线程还是其他线程,就取决于用户业务了。

tips: asio 的多路 io 复用模型 backend 也有 select 的实现,只是默认都用各平台高并发模型 epoll/kequeue/iocp/io_uring ,但可通过编译选项禁用他们,然后 fallback 到 select
Sep 6, 2022
Replied to a topic by justanetizen 程序员 推荐一个不错的 Cplusplus 网络库
当然,线程+阻塞 socket 也能实现异步,但线程资源更昂贵,这也是个各操作系统提供类似 epoll/kqueue/iocp/io_uring/select/poll+非阻塞 socket 多路 io 复用模型的原因。
Sep 6, 2022
Replied to a topic by justanetizen 程序员 推荐一个不错的 Cplusplus 网络库
游戏里的处理耗时事务,例如大量资源加载,分帧加载也是实现异步的一种思路,可有效避免界面卡顿。
不管是 iocp/epoll 等,还是 select/poll 都是实现多路 io 复用模型的方式,只是前者适用于实现高并发的服务器,后者多数情况下更适合适用于客户端,但无论如何,离开 nonblocking io(socket),高并发是空谈,异步 io 也是空谈。
Sep 6, 2022
Replied to a topic by justanetizen 程序员 推荐一个不错的 Cplusplus 网络库
异步只是结果或效果,epoll/kqueue/io_uring/iocp/poll/select+非阻塞 socket 可以实现,线程+阻塞 socket 也可以实现,协程也可以实现
About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1330 Online   Highest 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 12ms · UTC 17:03 · PVG 01:03 · LAX 10:03 · JFK 13:03
♥ Do have faith in what you're doing.