Comments (3)
Hi @jdanyow , thanks for bring this up. We have not yet discussed this, but we will definitely keep an eye on this. If the connect() API is standard across runtimes include Nodejs in the future, the custom socket feature PR 1540may able to handle it already. However, it definitely need to be tested.
The custom socket feature allow user to use a socket and its corresponding connect function beside the one we default used in tedious.
from tedious.
Hey @jdanyow,
I looked at this. It seems like the connect API is basically a way to get a network socket that implements the webstreams Duplex
API.
tedious
is currently built on top of the networking functionality provided by the net
and tls
modules - we probably can switch that longterm to using the connect
shim (which basically just provides web streams that tie back into nodejs' networking APIs).
It would involve some internal refactorings to switch to the web streams api, and we probably would also need to assess the performance impact of having that additional layer between tedious
and the nodejs networking APIs. If you want to investigate what changes this would require, feel free to open a PR so we can have an initial discussion. If you can't invest time into this, we will probably not be able to look into this anytime soon, as we have some other higher priority items that we'd like to focus on.
@MichaelSun90 I think the naming here is a bit confusing. The custom socket feature we provide won't work with this, as the custom socket feature expects a Node.js Stream compatible stream to be returned, whereas this connect
specification builds on top of web streams, which are not directly compatible.
from tedious.
Heard from the Cloudflare folks there's an ongoing effort to make the connect()
API standard across runtimes, including Node.js.
Spec: https://github.com/wintercg/proposal-sockets-api
Node implementation: https://github.com/Ethan-Arrowood/socket (published to npm here)
There's a few more weeks of work to polish these up, and further time to improve them based on feedback, but the intent is to make it easier for libraries to start using the connect() API — even before it's provided out-of-the-box in Node.js itself.
from tedious.
Related Issues (20)
- Why is the language used when connecting to SQLServer not the default language set by SQLServer? HOT 2
- [FEATURE REQUEST] AsyncIterator for Request class (promise-based streaming) HOT 4
- [High Severity] Regular Expression Denial of Service (ReDoS) in [email protected] introduced by tedious HOT 3
- [QUESTION] Expected behavior of parallel Strategy for MultiSubnetFailover option HOT 5
- Minor addition to exception information on failed bulk-load data due to type validation: Mention the failed column and errorneous value HOT 1
- Network socket not correctly cleaned up when connection timeout fires during TDS8.0 TLS negotiation HOT 2
- Unable to connect to Azure SQL using azure directory password authentication. HOT 2
- not able to connect to Microsoft Fabric HOT 6
- [QUESTION] How do I check the status of a connection? HOT 3
- Dead Links in documentation HOT 3
- unsupported type "BitN" from querying a BIT column HOT 5
- connection error: SSL routines:ssl_choose_client_version:unsupported HOT 2
- [perf] Performance loss on `<instance_members_initializer>` during token parsing HOT 3
- `MessageIO.prototype.startTls` should follow `tls.connect` semantics HOT 1
- Always Encrypted Roadmap
- Need to update @azure/msal-node to 2.0 for NodeJs 20 compatability HOT 9
- Login failure with caret (^) in password HOT 2
- [FEATURE REQUEST] HOT 3
- README Getting Started Links Out-of-Date HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tedious.