Swiftpack.co - Package - Kinvey/swift-sdk

Kinvey iOS SDK

badge-pod badge-languages badge-pms badge-platforms badge-status badge-coverage

The Kinvey iOS SDK is a package that can be used to develop iOS applications on the Kinvey platform. Refer to the Kinvey DevCenter for documentation on using Kinvey.

In the version 3 of the library, all new code is written in Swift and any application using v3 must also use Swift to access the API.

While we transition from Objective C to the latest Swift versions, we will use the following branching scheme. Please, pick the right version of our library depending of which langugage / version you are using:

| Language / Version | Kinvey SDK Version | Development Branch | | ------------------ | ------------------ | --------------- | | Swift 3 and Swift 4 | 3.3.0 and above | master | | Swift 2.3 | 3.2.x | 3.2 | | Objective-C | 1.x | 1.x |

Note:

  • The master branch represents the latest release of the SDK. See the CONTRIBUTING guidelines for details on submitting code.
  • On version 1.x, use the KinveyKit workspace. On all other versions, use the Kinvey workspace.

Building

You will need Carthage, Jazzy and Xcode command line tools installed to be able to build the SDK.

  • carthage build: build the dependencies frameworks using Carthage
  • make: runs a script that compile and generate the documentation files using Jazzy

Testing

Use Xcode to run the unit tests.

  • Open the file Kinvey.xcworkspace in Xcode
  • Select the Kinvey scheme
  • Select the menu item Product -> Test or press Command+U

Or run the command line:

make test

Important Note: adding the environment variables KINVEY_APP_KEY, KINVEY_APP_SECRET and KINVEY_MIC_APP_KEY will allow you to run the tests against a real Kinvey environment.

Releasing

We use GitFlow workflow for better management.

The workflow for releasing a new version of the SDK is as follows:

  1. Merge all waiting pull requests / feature branches on the develop branch.
  2. Bump the version running make set-version on the develop branch.
  3. Checkout the master branch and merge the develop branch.
  4. Tag the version with git.
  5. Push all changes.
  6. Upload the zip file containing all the binary files for Amazon AWS.
  7. Run make deploy-cocoapods in order to publish the new release for CocoaPods
  8. Publish release notes, API Reference Docs, and the Download section in the DevCenter repo.
  9. Push all changes to deploy.
  10. Send the email with the release notes for the Customer Service and Development team

Version Management

Updating the sdk version should follow Semantic Version 2.0.0:

  • Major (x.0.0): when making an incompatible API changes.
  • Minor (3.x.0): when adding functionality in a backwards-compatible manner.
  • Patch (3.0.x): when making backwards-compatible bug fixes or enhancements.

License

See LICENSE for details.

Contributing

See CONTRIBUTING.md for details on reporting bugs and making contributions.

Github

link
Stars: 2
Help us keep the lights on

Dependencies

Used By

Total: 0

Releases

3.18.0 - Jul 12, 2018

Improvements

Bugfixes

  • Fixed memory leak in DataStore.removeAll() (#304)

Deprecated

  • ObjectMapper is now deprecated in favor of Swift.Codable

Breaking Changes

  • Entity.CodingKeys renamed to Entity.EntityCodingKeys to avoid confusions when subclassing Entity
  • DataStore<MyEntity>.collection() now can throw errors, so a try is now required, for example: try DataStore<MyEntity>.collection()
  • Options() constructor now can throw erros, so a try is now required, for example: try Options(timeout: 120)
  • Custom types used in CustomEndpoint calls now requires to provide implement the JSONDecodable protocol

3.17.1 - Jun 26, 2018

Improvements

  • Returning support for tvOS on CocoaPods (#299)
  • New Error Kinvey.Error.blRuntimeError to handle BL runtime errors (#301)

Bugfixes

  • None

Deprecated

  • Client.ping(completionHandler:)
  • Push.unRegisterDeviceToken(_:)

Breaking Changes

  • None

3.17.0 - Jun 15, 2018

Improvements

  • Better code coverage (#297)

Bugfixes

  • None

Deprecated

  • Client.initialize(appKey:appSecret:accessGroup:apiHostName:authHostName:encrypted:schema:completionHandler:)
  • Client.initialize(appKey:appSecret:accessGroup:apiHostName:authHostName:encryptionKey:schema:completionHandler:)
  • CustomEndpoint.CompletionHandler
  • CustomEndpoint.execute(_:params:client:completionHandler:)
  • DataStore.pull(_:deltaSetCompletionHandler:deltaSet:completionHandler:)
  • DataStore.purge(_:completionHandler:)
  • DataStore.push(timeout:completionHandler:)
  • DataStore.sync(_:deltaSetCompletionHandler:deltaSet:completionHandler:)
  • Entity.Key.acl
  • Entity.Key.entityId
  • Entity.Key.metadata
  • FileStore.download(_:storeType:ttl:completionHandler:)
  • FileStore.download(_:ttl:completionHandler:)
  • FileStore.find(_:ttl:completionHandler:)
  • FileStore.refresh(_:ttl:completionHandler:)
  • FileStore.remove(_:completionHandler:)
  • FileStore.upload(_:data:ttl:completionHandler:)
  • FileStore.upload(_:image:imageRepresentation:ttl:completionHandler:)
  • FileStore.upload(_:path:ttl:completionHandler:)
  • FileStore.upload(_:stream:ttl:completionHandler:)
  • Metadata.Key.authtoken
  • Metadata.Key.entityCreationTime
  • Metadata.Key.lastModifiedTime
  • User.PersistableUsernameKey
  • User.changePassword(newPassword:completionHandler:)
  • User.exists(username:client:completionHandler:)
  • User.forgotUsername(email:client:completionHandler:)
  • User.get(userId:client:completionHandler:)
  • User.login(authSource:_:createIfNotExists:authServiceId:client:completionHandler:)
  • User.lookup(_:completionHandler:)
  • User.resetPassword(usernameOrEmail:client:completionHandler:)
  • User.save(newPassword:completionHandler:)
  • User.sendEmailConfirmation(forUsername:client:completionHandler:)
  • User.signup(username:password:user:client:completionHandler:)

Breaking Changes

  • Client.initialize(appKey:appSecret:accessGroup:apiHostName:authHostName:encrypted:schemaVersion:migrationHandler:)
  • Client.initialize(appKey:appSecret:accessGroup:apiHostName:authHostName:encryptionKey:schemaVersion:migrationHandler:)
  • Client.timeoutInterval
  • DataStore.collection(_:deltaSet:autoPagination:client:tag:validationStrategy:)
  • DataStore.count(_:readPolicy:completionHandler:)
  • DataStore.find(_:deltaSet:readPolicy:completionHandler:)
  • DataStore.find(_:readPolicy:completionHandler:)
  • DataStore.find(byId:readPolicy:completionHandler:)
  • DataStore.getInstance(_:deltaSet:client:tag:validationStrategy:)
  • DataStore.group(count:countType:condition:readPolicy:completionHandler:)
  • DataStore.group(keys:avg:avgType:condition:readPolicy:completionHandler:)
  • DataStore.group(keys:initialObject:reduceJSFunction:condition:readPolicy:completionHandler:)
  • DataStore.group(keys:max:maxType:condition:readPolicy:completionHandler:)
  • DataStore.group(keys:min:minType:condition:readPolicy:completionHandler:)
  • DataStore.group(keys:sum:sumType:condition:readPolicy:completionHandler:)
  • DataStore.pull(_:deltaSet:deltaSetCompletionHandler:completionHandler:)
  • DataStore.remove(_:writePolicy:completionHandler:)
  • DataStore.remove(byId:writePolicy:completionHandler:)
  • DataStore.remove(byIds:writePolicy:completionHandler:)
  • DataStore.removeAll(_:completionHandler:)
  • DataStore.removeById(_:writePolicy:completionHandler:)
  • DataStore.save(_:writePolicy:completionHandler:)
  • FileStore.getInstance(client:)
  • FileStore.getInstance(fileType:client:)
  • Metadata.AuthTokenKey
  • Metadata.EctKey
  • Metadata.LmtKey
  • Options.init(_:)
  • User.destroy(userId:hard:client:completionHandler:)
  • User.find(query:client:completionHandler:)
  • User.login(redirectURI:micURL:authServiceId:client:)
  • User.presentMICViewController(redirectURI:timeout:forceUIWebView:authServiceId:client:completionHandler:)
  • User.resetPassword(email:client:completionHandler:)
  • User.resetPassword(username:client:completionHandler:)

3.16.0 - Jun 1, 2018

Improvements

  • MIC support for the Resource Owner Credentials Grant flow (#290)
  • Outdated compiler warnings removed (#291)

Bugfixes

  • Use autopaging when Delta Sync is not available (#289)
  • Fix inconsistencies when Delta Sync is enabled and an autopaging request fails (#292)
  • Bugfix: Fix inconsistencies when Delta Sync is enabled and fields is used in the query (#293)
  • Bugfix: Correctly handle OAuth MIC errors in a returned redirect URI (#294)

Deprecated

  • User.login(redirectURI:username:password:). Use User.login(username:password:provider:options:completionHandler:) instead

Breaking Changes

  • None

3.15.0 - May 15, 2018

Improvements

  • X-Kinvey-Device-Info is a new header that includes more information about the device (#282)
  • Upgrading PromiseKit to version 6 (#284)
  • The client-side Delta Set feature has been replaced by a server-side implementation called Delta Sync that offers better performance and scalability (#261, #286, #287)
  • Default log level is now .warning (#283)

Bugfixes

  • Make the ValidationStrategy work as intended (#285)
  • Canceling DataStore.find() requests not working in some situations (#288)

Deprecated

  • None

Breaking Changes

  • None