For 2.x and 3.x upgrade help please checkout the 3.x branch
I will try to cover all changes made
Likelihood Of Impact: Medium
Because the API function _Io_Reconnect is removed, the $bAutoReconnect
parameter becomes obselete.
- _Io_Connect($sAddress, $iPort, $bAutoReconnect = True) changed into _Io_Connect($sAddress, $iPort)
- _Io_Listen($iPort, $sAddress = @IPAddress1, $iMaxPendingConnections = Default, $iMaxDeadSocketsBeforeTidy = 1000, $iMaxConnections = 100000) changed into _Io_Listen($iPort, $sAddress = @IPAddress1, $iMaxPendingConnections = Default)
- Default value for
_Io_SetRecvPackageSize
changed from4096
to8192
_Io_getSockets()
now returns a scripting object containing all connected sockets and their properties. Read more about how Scripting Dictionaries work here- _Io_getSockets($bForceUpdate = False, $socket = $g__io_mySocket, $whoAmI = $g__io_whoami) changed into
_Io_getSockets()
Likelihood Of Impact: Very High
This list might change in the non-beta release but for now, these API functions are no longer available because they are replaced by something cooler, or that they does not exist in the core UDF.
- _Io_Ban (Might come back as a optinal feature)
- _Io_getBanlist (Might come back as a optinal feature)
- _Io_Sanction (Might come back as a optinal feature)
- _Io_IsBanned (Might come back as a optinal feature)
- _Io_getMaxConnections
- _Io_getMaxDeadSocketsCount
- _Io_getSocketsCount
- _Io_getFirstByProperty
- _Io_getActiveSocketCount (A substitute to this would be to call
Io_getSockets().count()
) - _Io_socketGetProperty (A substitute to this would be to call
Io_getSockets().item($socket).item("propName")
) - _Io_socketSetProperty (A substitute to this would be to call
Io_getSockets().item($socket).add("CustomPropName", "customValue")
) - _Io_getSocketsCount
- _Io_TransferSocket
- _Io_TidyUp Since we moved from arrays to Scripting Dictionaries, we no longer have to "Tidy up", that is done automagicly thanks to our events
- _Io_Reconnect
- _Io_RegisterMiddleware (use event listeners instead, checkout the Docs/EVENTS.md file for more information)
- _Io_unRegisterMiddleware
- _Io_unRegisterEveryMiddleware
Likelihood Of Impact: Low
Because of the source code decoupling, some API functions may be excluded in your project to minimize bloat.
SocketIO.au3
now only contains the MIT license and some #includes
the actual code is now stored in SocketIO-Core.au3
giving you the opportunity to exclude some functionality .
- _Io_Emit
- _Io_Broadcast
- _Io_BroadcastToAll
- _Io_getSubscriberRooms
- _Io_Subscribe
- _Io_UnSubscribe
- _Io_UnsubscribeFromAll
- _Io_BroadcastToRoom
- _Io_DevDebug
In the API reference you can see where the features are stored.