我正在使用 ioRedis 节点包将我的 Node js 应用程序连接到受 TLS 保护的 Redis 服务器。我使用的Redis版本是Redis 6.0。我的服务器使用证书运行良好,但从节点应用程序连接时出现错误。
Redis({
host: "localhost",
port: 6379,
tls: {
key: fs.readFileSync('./redis.key'),
cert: fs.readFileSync('./redis.crt'),
maxVersion: 'TLSv1.3',
minVersion: 'TLSv1.3',
ca: [fs.readFileSync('./redis.pem')]
}
})
Run Code Online (Sandbox Code Playgroud)
Nodejs应用程序端的错误是
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
Error: read ECONNRESET
at TCP.onStreamRead (internal/stream_base_commons.js:205:27)
Run Code Online (Sandbox Code Playgroud)
尝试从 Nodejs 应用程序连接时服务器出错
17:29:44.295 # Error accepting a client connection: error:1408F10B:SSL …
XMLHttpRequest:网络错误0x800c0019,访问此资源所需的安全证书无效
如何在 nodejs 中发送 httpVersion 2.0 请求?
我已经尝试了几乎所有的请求模块,而且都是 httpVersion 1.1
Nodejs 不能像 java 和 .net 那样有内置的线程 API。如果添加线程,语言本身的性质将发生变化。不可能将线程添加为一组新的可用类或函数。
Nodejs 10.x 添加了工作线程作为实验,现在自 12.x 起稳定。我浏览了几篇博客,但可能由于缺乏知识而不太了解。它们与线程有何不同。
我正在 Deno 中创建 REST API,但无法获得少量资源。有人可以帮助我开始吗?类似于 express router 的东西:
router.get('/', function (req, res) {
});
router.post('/savedata', function (req, res) {
});
Run Code Online (Sandbox Code Playgroud) 我使用的是Ignite 2.6,它作为一个独立的Java应用程序运行良好,但它不适用于spring boot.我收到了这个错误
[20:44:18,520][SEVERE][exchange-worker-#37][GridDhtPartitionsExchangeFuture] Failed to reinitialize local partitions (preloading will be stopped): GridDhtPartitionExchangeId [topVer=AffinityTopologyVersion [topVer=8, minorTopVer=0], discoEvt=DiscoveryEvent [evtNode=TcpDiscoveryNode [id=ee3f7ea5-e448-4659-8148-232db27efde6, addrs=[0:0:0:0:0:0:0:1, 127.0.0.1, 192.168.0.52, 2406:7400:5c:13e0:44bc:65c7:241c:3804, 2406:7400:5c:13e0:d1cb:e1a9:15c5:c8ae], sockAddrs=[/2406:7400:5c:13e0:44bc:65c7:241c:3804:0, /0:0:0:0:0:0:0:1:0, /127.0.0.1:0, /192.168.0.52:0, /2406:7400:5c:13e0:d1cb:e1a9:15c5:c8ae:0], discPort=0, order=8, intOrder=0, lastExchangeTime=1538666050349, loc=true, ver=2.6.0#20180710-sha1:669feacc, isClient=true], topVer=8, nodeId8=ee3f7ea5, msg=null, type=NODE_JOINED, tstamp=1538666058292], nodeId=ee3f7ea5, evt=NODE_JOINED]
class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed to initialize DB connection: jdbc:h2:mem:ee3f7ea5-e448-4659-8148-232db27efde6;LOCK_MODE=3;MULTI_THREADED=1;DB_CLOSE_ON_EXIT=FALSE;DEFAULT_LOCK_TIMEOUT=10000;FUNCTIONS_IN_SCHEMA=true;OPTIMIZE_REUSE_RESULTS=0;QUERY_CACHE_SIZE=0;RECOMPILE_ALWAYS=1;MAX_OPERATION_MEMORY=0;NESTED_JOINS=0;BATCH_JOINS=1;ROW_FACTORY="org.apache.ignite.internal.processors.query.h2.opt.GridH2PlainRowFactory";DEFAULT_TABLE_ENGINE=org.apache.ignite.internal.processors.query.h2.opt.GridH2DefaultTableEngine
at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing$1.initialValue(IgniteH2Indexing.java:330)
at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing$1.initialValue(IgniteH2Indexing.java:298)
at java.lang.ThreadLocal.setInitialValue(Unknown Source)
at java.lang.ThreadLocal.get(Unknown Source)
at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing$1.get(IgniteH2Indexing.java:300)
at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing$1.get(IgniteH2Indexing.java:298)
at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.connectionForThread(IgniteH2Indexing.java:524)
at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeStatement(IgniteH2Indexing.java:592)
at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.createSchema(IgniteH2Indexing.java:561)
at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.registerCache(IgniteH2Indexing.java:2760)
at org.apache.ignite.internal.processors.query.GridQueryProcessor.registerCache0(GridQueryProcessor.java:1594)
at org.apache.ignite.internal.processors.query.GridQueryProcessor.onCacheStart0(GridQueryProcessor.java:799)
at org.apache.ignite.internal.processors.query.GridQueryProcessor.onCacheStart(GridQueryProcessor.java:860) …
Run Code Online (Sandbox Code Playgroud) 我是新手ETCD
,我想知道可以存储在的值是否有大小限制ETCD
?