aotrautils-srv 0.0.1879 → 0.0.1881
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
-
/*utils COMMONS library associated with aotra version : «1_29072022-2359 (19/06/2026-
|
|
3
|
+
/*utils COMMONS library associated with aotra version : «1_29072022-2359 (19/06/2026-20:42:57)»*/
|
|
4
4
|
/*-----------------------------------------------------------------------------*/
|
|
5
5
|
|
|
6
6
|
|
|
@@ -5470,7 +5470,7 @@ AOTRAUTILS_LIB_IS_LOADED=true;
|
|
|
5470
5470
|
|
|
5471
5471
|
|
|
5472
5472
|
|
|
5473
|
-
/*utils AI library associated with aotra version : «1_29072022-2359 (19/06/2026-
|
|
5473
|
+
/*utils AI library associated with aotra version : «1_29072022-2359 (19/06/2026-20:42:57)»*/
|
|
5474
5474
|
/*-----------------------------------------------------------------------------*/
|
|
5475
5475
|
|
|
5476
5476
|
|
|
@@ -5730,7 +5730,7 @@ getLLMAPIClient=(modelName, apiURL, agentRole, defaultPrompt, llmProviderName=DE
|
|
|
5730
5730
|
|
|
5731
5731
|
|
|
5732
5732
|
|
|
5733
|
-
/*utils CONSOLE library associated with aotra version : «1_29072022-2359 (19/06/2026-
|
|
5733
|
+
/*utils CONSOLE library associated with aotra version : «1_29072022-2359 (19/06/2026-20:42:57)»*/
|
|
5734
5734
|
/*-----------------------------------------------------------------------------*/
|
|
5735
5735
|
|
|
5736
5736
|
|
|
@@ -5768,7 +5768,6 @@ if(typeof(window)==="undefined") window=global;
|
|
|
5768
5768
|
|
|
5769
5769
|
//*********************************** AUTO-ORGANIZING REAL-TIME AORTAC CLUSTERIZATION (AORTAC) *********************************** */
|
|
5770
5770
|
|
|
5771
|
-
const AORTAC_CLIENT_FORCE_SSL_USAGE=true;
|
|
5772
5771
|
|
|
5773
5772
|
// New implementation :
|
|
5774
5773
|
|
|
@@ -5787,7 +5786,6 @@ class AORTACClientCell{
|
|
|
5787
5786
|
this.protocol=nonull(infos.protocol,"ws");
|
|
5788
5787
|
this.host=nonull(infos.host,"localhost");
|
|
5789
5788
|
this.port=nonull(infos.port,"30000");
|
|
5790
|
-
this.usesSSL=AORTAC_CLIENT_FORCE_SSL_USAGE;
|
|
5791
5789
|
|
|
5792
5790
|
this.startTime=null;
|
|
5793
5791
|
|
|
@@ -5832,7 +5830,7 @@ class AORTACClientCell{
|
|
|
5832
5830
|
self.handleClientHelloSequence(resolve);
|
|
5833
5831
|
|
|
5834
5832
|
|
|
5835
|
-
}, self.protocol+"://"+self.host, self.port
|
|
5833
|
+
}, self.protocol+"://"+self.host, self.port);
|
|
5836
5834
|
self.initialClientInstance.client.start();
|
|
5837
5835
|
|
|
5838
5836
|
});
|
|
@@ -5911,7 +5909,6 @@ class AORTACClientCell{
|
|
|
5911
5909
|
const protocol=nonull(infos.protocol,"ws");
|
|
5912
5910
|
const host=nonull(infos.host,"localhost");
|
|
5913
5911
|
const port=nonull(infos.port,"30000");
|
|
5914
|
-
const usesSSL=AORTAC_CLIENT_FORCE_SSL_USAGE;
|
|
5915
5912
|
|
|
5916
5913
|
const reconnectedClientInstance=initClient(self.isNodeContext, false, (socketToServerClientInstance, reconnectedClientInstanceLocal)=>{
|
|
5917
5914
|
|
|
@@ -5927,7 +5924,7 @@ class AORTACClientCell{
|
|
|
5927
5924
|
self.handleReconnectedClientHelloSequence(reconnectedClientInstance, resolve)
|
|
5928
5925
|
|
|
5929
5926
|
|
|
5930
|
-
}, protocol+"://"+host, port
|
|
5927
|
+
}, protocol+"://"+host, port);
|
|
5931
5928
|
|
|
5932
5929
|
self.clientInstances[serverOrigin]=reconnectedClientInstance;
|
|
5933
5930
|
reconnectedClientInstance.client.start();
|
|
@@ -6344,7 +6341,7 @@ class AORTACServerCell{
|
|
|
6344
6341
|
// For this, use the socketToServerClientInstance attribute instead :
|
|
6345
6342
|
outcomingCell.socketToServerClientInstance=socketToServerClientInstance;
|
|
6346
6343
|
|
|
6347
|
-
}, outcomingCellProtocol+"://"+outcomingCellHost, outcomingCellPort
|
|
6344
|
+
}, outcomingCellProtocol+"://"+outcomingCellHost, outcomingCellPort);
|
|
6348
6345
|
|
|
6349
6346
|
clientInstance.client.start();
|
|
6350
6347
|
|
|
@@ -8186,9 +8183,13 @@ WebsocketImplementation={
|
|
|
8186
8183
|
return null;
|
|
8187
8184
|
}
|
|
8188
8185
|
|
|
8186
|
+
// TRACE
|
|
8187
|
+
lognow("INFO : CLIENT : Trying to establish connection to server (serverURL:«"+serverURL+"» ; port:«"+port+"» ; isSecure:«"+isSecure+"»)");
|
|
8188
|
+
|
|
8189
|
+
|
|
8189
8190
|
clientSocket=new WebSocket(serverURL+":"+port,/*WORKAROUND:*/{
|
|
8190
8191
|
// CAUTION : SECURITY BREACH :
|
|
8191
|
-
// BUT ALSO NECESSARY TO ALLOW SELF-SIGNED CERTIFICATES USAGE WITH THE YESBOT SYSTEM !
|
|
8192
|
+
// BUT ALSO NECESSARY TO ALLOW SELF-SIGNED CERTIFICATES USAGE WITH THE YESBOT SYSTEM ON DEV ENVIRONMENTS !
|
|
8192
8193
|
rejectUnauthorized:false, // (THIS IS A KNOWN SECURITY BREACH)
|
|
8193
8194
|
secure: isSecure
|
|
8194
8195
|
});
|
|
@@ -9068,14 +9069,17 @@ if(typeof(window)==="undefined") window=global;
|
|
|
9068
9069
|
// -Client :
|
|
9069
9070
|
|
|
9070
9071
|
// TODO : Use everywhere it's applicable !
|
|
9071
|
-
initClient=function(isNodeContext=true, useSocketIOImplementation=/*DEBUG*/false, doOnServerConnection=null, url, /*OPTIONAL*/port=25000,
|
|
9072
|
+
initClient=function(isNodeContext=true, useSocketIOImplementation=/*DEBUG*/false, doOnServerConnection=null, url, /*OPTIONAL*/port=25000, /*OPTIONAL*/timeout=10000, /*OPTIONAL*/selfParam=null){
|
|
9073
|
+
|
|
9074
|
+
const isSecure=(contains(url.toLowerCase(),"https:") || contains(url.toLowerCase(),"wss:"));
|
|
9075
|
+
|
|
9072
9076
|
let aotraClient={};
|
|
9073
9077
|
|
|
9074
9078
|
aotraClient.client={};
|
|
9075
9079
|
aotraClient.client.start=function(){
|
|
9076
9080
|
|
|
9077
9081
|
// DBG
|
|
9078
|
-
lognow("INFO : Setting up client :... (url:«"+url+"
|
|
9082
|
+
lognow("INFO : Setting up client :... (url:«"+url+"» ; port:«"+port+"»)");
|
|
9079
9083
|
|
|
9080
9084
|
let socketToServerClientInstance=WebsocketImplementation.getStatic(isNodeContext, useSocketIOImplementation).connectToServer(url, port, isSecure, timeout);
|
|
9081
9085
|
if(!socketToServerClientInstance){
|
aotrautils-srv/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "aotrautils-srv",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.1881",
|
|
4
4
|
"main": "aotrautils-srv.build.js",
|
|
5
5
|
"description": "A library for vanilla javascript utils (server-side) used in aotra javascript CMS",
|
|
6
6
|
"author": "Jeremie Ratomposon <info@alqemia.com> (https://alqemia.com)",
|