SwiftChangelog for PubNub Swift Native SDK

 
The PubNub Swift 3.0 SDK contains many significant changes from the 2.x SDK, including breaking changes. Please refer to the PubNub Swift 3.0 Migration Guide for more details.
Added
  • CryptoStream and CryptoInputStream can be used to perform crypto operations on streams of data

  • File upload/download support

  • Added includeUUID and includeMessageType flags to History

Modified
  • History will now has a default limit of 100 for single-channel and 25 for multichannel requests

  • Removed depcreated platform version support to align with Xcode 12 warnings

Fixed
  • Fixed crash when performing many requests simulataneously

Added
  • Added Objects v2 API and removed Objects v1 API

Modified
  • Replace PubNub API response objects with primitives or prtocols

  • Replace Subscribe Event objects with primitives or prtocols

  • Subscribe Listener now has a batched event handler

  • Renamed several APIs to align naming across all APIs

  • PubNubConfiguration properites can all be set through default init

  • Reduced access control of objects that are not public facing

  • Request level configuration available for most PubNub APIs

Fixed
  • Fixed crash when performing many requests simulataneously

Modified
  • Payload and FCMTarget fields are now optional for PubNubPushMessage

Fixed
  • Fixed an issue where nested presence state could be published

Fixed
  • Resolves possible memory leaks related to listeners

  • Responds with the appropriate error when a Signal payload is too large

  • Added PAM support to Channels for Channel-Group endpoint

  • Invalid JSON will attempt to be parsed for the next Timetoken, and if successful will no interrupt the current subscription loop

Fixed
  • Add uuid and channel to the Message Action Event

  • Fixed typos inside log messages

Modified
  • AnyJSON dictionaries can now perform a rawValue subscript that will return the underlying Any object

Modified
  • Message Subscribe Events and Message History will now return the decrypted Data blob in the event it was decrypted, but couldn't be stringified

  • Crypto will now accept the type of String.Encoding to be used when converting between Data and String

  • Object API fetch|create|update methods with generic response objects have been added

  • Object API fetch|create|update methods with protocol response objects have been added

  • Object types User|Space|Member|Membership can now convert the underlying type using transocde(into:)

Fixed
  • Corrected the access control level of MembershipIdentifiable properties

  • User/Space Subscription Update events wouldn't properly handle partial object updates

Fixed
  • Make region optional during originTimetoken parsing and set to 0 by default

Fixed
  • A reconnecting event will be emitted once subscription starts retrying

Added
  • PAM Token Management System added to manage Object API auth tokens

Fixed
  • HereNow Presence will now work when only groups are being used

Fixed
  • Enable ability to send auth token on Presence endpoints

Fixed
  • Subscription requests will now properly cancel when updating existing subscription loop

Fixed
  • Duplicate subscription will no longer start if a current subscription is connecting

  • Added missing APNS2 pubnub config field to publish payload object

  • Fixed Coding issue when a scalar value is used for APNS2 publish payload object

  • Subscription will no long attempt to automatically reconnect after an unexpected disconnet

Added
  • Added convenience objects for creating push publish messages

  • List/Add/Remove/Remove-All of APNS2 push channels for devices

Fixed
  • Channel property on push responses is not public

Modified
  • Timetoken was changed from an Int64 to UInt64 to avoid negative timetoken values

  • Removed PubNubRouter, and replaced with multiple service specific HTTPRouter implementations

  • Removed Endpoint type

  • Renamed Response to EndpointResponse

  • Removed HTTPHeader & HTTPHeader, and replaced with [String: String]

  • Renamed Session to HTTPSession and made it an internal type

  • Created RequestReplaceable and made Request an internal type

Fixed
  • PubNub Info.plist is now included on Cocoapod and Carthage deployed builds

Fixed
  • Encoding JSONCodableScalar values will now properly encode to a single value

  • Membership APIs no longer use hardcoded subscribe key

Added
  • Added support for Message Action Subscription Listener

  • Fetch previously published Message Actions and Messages via History APIs

  • Fetch previously published Message Actions on a channel

  • Add/Remove Message Actions on previously published messages

Fixed
  • Add/Update documentation for public classes, methods, and properties

Fixed
  • Update the version inside the podspec file

Fixed
  • Subscribe/Unsubscribe will now properly cancel/restart the subscribe loop when completely stoppping cycle

  • Fixed memory leak inside Hearthbeat response handler

  • Fixed memory leak inside SubscriptionSessionFactory

Modified
  • PNError enum has been replaced by PubNubError struct to allow for greater flexibility in error handling and recognition

  • AnyJSON as been replaced by the JSONCodable protocol for method parameters allowing any conforming object to be passed

  • Removed initialized and cancelled as ConnectionsStatus options

  • Response error events due to cancellations will now be suppresed by default by the SubscriptionListener. They can be toggled on using a the supressCancellationErrors property

Added
  • Added subscription event listener for subscribe/unsubscribe changes

Modified
  • Made the subscription token a property on the listener for cleaner setup

Modified
  • Removed development dependencies from being included in Swift Package imports

  • Added meta event listener covering all event types

Added
  • Support for Objects added

Fixed
  • Changed ConnectionStatus.isActive and ConnectionStatus.isConnected access control to public

  • Fixed typo in PubNub.Push method parameters

  • Add support for Global HereNow

  • Fixed HereNow stateless response decoding

  • Fixed HereNow single channel response decoding

Added
  • Add support for Signal Subscription Listener

  • Add support for Signal publish API

Fixed
  • Fixed crash attempting to create URLSessionTasks from invalidated URLSession

  • Default Encryption/Decryption methodology now properly aligns with other SDKs

  • ? characters inside URL query parameters will now be properly url encoded

Modified
  • Exposed add(listener:) to be called by PubNub instance directly

Added
  • Initial release of native Swift PubNub SDK