diff --git a/AWSAPIGateway.podspec b/AWSAPIGateway.podspec index 8bbafe0a320..8dd9cf76ea0 100644 --- a/AWSAPIGateway.podspec +++ b/AWSAPIGateway.podspec @@ -1,7 +1,7 @@ Pod::Spec.new do |s| s.name = 'AWSAPIGateway' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -13,7 +13,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSAPIGateway/*.{h,m}' end diff --git a/AWSAPIGateway/AWSAPIGatewayClient.m b/AWSAPIGateway/AWSAPIGatewayClient.m index dd7f8fecff9..5558041905c 100644 --- a/AWSAPIGateway/AWSAPIGatewayClient.m +++ b/AWSAPIGateway/AWSAPIGatewayClient.m @@ -23,7 +23,7 @@ static NSString *const AWSAPIGatewayAPIKeyHeader = @"x-api-key"; -static NSString *const AWSAPIGatewaySDKVersion = @"2.6.2"; +static NSString *const AWSAPIGatewaySDKVersion = @"2.6.3"; static int defaultChunkSize = 1024; diff --git a/AWSAPIGateway/Info.plist b/AWSAPIGateway/Info.plist index 35cb69f6849..ac6ab5362f5 100644 --- a/AWSAPIGateway/Info.plist +++ b/AWSAPIGateway/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSAuth.podspec b/AWSAuth.podspec index ba13581b7bd..ef89fe7bc48 100644 --- a/AWSAuth.podspec +++ b/AWSAuth.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSAuth' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -14,23 +14,23 @@ Pod::Spec.new do |s| s.requires_arc = true s.subspec 'Core' do |authcore| - authcore.dependency 'AWSAuthCore', '2.6.2' + authcore.dependency 'AWSAuthCore', '2.6.3' end s.subspec 'FacebookSignIn' do |facebook| - facebook.dependency 'AWSFacebookSignIn', '2.6.2' + facebook.dependency 'AWSFacebookSignIn', '2.6.3' end s.subspec 'GoogleSignIn' do |google| - google.dependency 'AWSGoogleSignIn', '2.6.2' + google.dependency 'AWSGoogleSignIn', '2.6.3' end s.subspec 'UserPoolsSignIn' do |up| - up.dependency 'AWSUserPoolsSignIn', '2.6.2' + up.dependency 'AWSUserPoolsSignIn', '2.6.3' end s.subspec 'UI' do |ui| - ui.dependency 'AWSAuthUI', '2.6.2' + ui.dependency 'AWSAuthUI', '2.6.3' end end diff --git a/AWSAuthCore.podspec b/AWSAuthCore.podspec index 5485b883f1a..62dbc3e6038 100644 --- a/AWSAuthCore.podspec +++ b/AWSAuthCore.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSAuthCore' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,7 +12,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSAuthSDK/Sources/AWSAuthCore/*.{h,m}' s.public_header_files = 'AWSAuthSDK/Sources/AWSAuthCore/*.h' end diff --git a/AWSAuthSDK/Sources/AWSAuthCore/Info.plist b/AWSAuthSDK/Sources/AWSAuthCore/Info.plist index 2ef43332672..1ad1af6fbea 100644 --- a/AWSAuthSDK/Sources/AWSAuthCore/Info.plist +++ b/AWSAuthSDK/Sources/AWSAuthCore/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleVersion $(CURRENT_PROJECT_VERSION) NSPrincipalClass diff --git a/AWSAuthSDK/Sources/AWSAuthUI/Info.plist b/AWSAuthSDK/Sources/AWSAuthUI/Info.plist index 2ef43332672..1ad1af6fbea 100644 --- a/AWSAuthSDK/Sources/AWSAuthUI/Info.plist +++ b/AWSAuthSDK/Sources/AWSAuthUI/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleVersion $(CURRENT_PROJECT_VERSION) NSPrincipalClass diff --git a/AWSAuthSDK/Sources/AWSFacebookSignIn/Info.plist b/AWSAuthSDK/Sources/AWSFacebookSignIn/Info.plist index 2ef43332672..1ad1af6fbea 100644 --- a/AWSAuthSDK/Sources/AWSFacebookSignIn/Info.plist +++ b/AWSAuthSDK/Sources/AWSFacebookSignIn/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleVersion $(CURRENT_PROJECT_VERSION) NSPrincipalClass diff --git a/AWSAuthSDK/Sources/AWSGoogleSignIn/Info.plist b/AWSAuthSDK/Sources/AWSGoogleSignIn/Info.plist index 2ef43332672..1ad1af6fbea 100644 --- a/AWSAuthSDK/Sources/AWSGoogleSignIn/Info.plist +++ b/AWSAuthSDK/Sources/AWSGoogleSignIn/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleVersion $(CURRENT_PROJECT_VERSION) NSPrincipalClass diff --git a/AWSAuthSDK/Sources/AWSUserPoolsSignIn/Info.plist b/AWSAuthSDK/Sources/AWSUserPoolsSignIn/Info.plist index 2ef43332672..1ad1af6fbea 100644 --- a/AWSAuthSDK/Sources/AWSUserPoolsSignIn/Info.plist +++ b/AWSAuthSDK/Sources/AWSUserPoolsSignIn/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleVersion $(CURRENT_PROJECT_VERSION) NSPrincipalClass diff --git a/AWSAuthUI.podspec b/AWSAuthUI.podspec index 9974bf087b3..d8c95cbb52e 100644 --- a/AWSAuthUI.podspec +++ b/AWSAuthUI.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSAuthUI' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,8 +12,8 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' - s.dependency 'AWSAuthCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' + s.dependency 'AWSAuthCore', '2.6.3' s.source_files = 'AWSAuthSDK/Sources/AWSAuthUI/*.{h,m}', 'AWSAuthSDK/Sources/AWSAuthUI/**/*.{h,m}', 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/AWSFormTableCell.h', 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/AWSTableInputCell.h', 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/AWSFormTableDelegate.h', 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/AWSUserPoolsUIHelper.h' s.public_header_files = 'AWSAuthSDK/Sources/AWSAuthUI/AWSAuthUI.h', 'AWSAuthSDK/Sources/AWSAuthUI/AWSAuthUIViewController.h', 'AWSAuthSDK/Sources/AWSAuthUI/AWSAuthUIConfiguration.h' s.private_header_files = 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/AWSFormTableCell.h', 'AWSAuthSDK/Sources/AWSAuthUI/AWSSignInViewController.h', 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/AWSTableInputCell.h', 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/AWSFormTableDelegate.h', 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/AWSUserPoolsUIHelper.h' diff --git a/AWSAutoScaling.podspec b/AWSAutoScaling.podspec index 60e5fd24d8b..b51d66a719c 100644 --- a/AWSAutoScaling.podspec +++ b/AWSAutoScaling.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSAutoScaling' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSAutoScaling/*.{h,m}' end diff --git a/AWSAutoScaling/AWSAutoScalingService.m b/AWSAutoScaling/AWSAutoScalingService.m index c7b9bf72242..62e3ac43906 100644 --- a/AWSAutoScaling/AWSAutoScalingService.m +++ b/AWSAutoScaling/AWSAutoScalingService.m @@ -26,7 +26,7 @@ #import "AWSAutoScalingResources.h" static NSString *const AWSInfoAutoScaling = @"AutoScaling"; -static NSString *const AWSAutoScalingSDKVersion = @"2.6.2"; +static NSString *const AWSAutoScalingSDKVersion = @"2.6.3"; @interface AWSAutoScalingResponseSerializer : AWSXMLResponseSerializer diff --git a/AWSAutoScaling/Info.plist b/AWSAutoScaling/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSAutoScaling/Info.plist +++ b/AWSAutoScaling/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSCloudWatch.podspec b/AWSCloudWatch.podspec index 988c8cfc0f2..9718eeeb514 100644 --- a/AWSCloudWatch.podspec +++ b/AWSCloudWatch.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSCloudWatch' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSCloudWatch/*.{h,m}' end diff --git a/AWSCloudWatch/AWSCloudWatchService.m b/AWSCloudWatch/AWSCloudWatchService.m index b75d672a9bf..4499d9da183 100644 --- a/AWSCloudWatch/AWSCloudWatchService.m +++ b/AWSCloudWatch/AWSCloudWatchService.m @@ -26,7 +26,7 @@ #import "AWSCloudWatchResources.h" static NSString *const AWSInfoCloudWatch = @"CloudWatch"; -static NSString *const AWSCloudWatchSDKVersion = @"2.6.2"; +static NSString *const AWSCloudWatchSDKVersion = @"2.6.3"; @interface AWSCloudWatchResponseSerializer : AWSXMLResponseSerializer diff --git a/AWSCloudWatch/Info.plist b/AWSCloudWatch/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSCloudWatch/Info.plist +++ b/AWSCloudWatch/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSCognito.podspec b/AWSCognito.podspec index 7e93001fbf9..f65128aa3e7 100644 --- a/AWSCognito.podspec +++ b/AWSCognito.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSCognito' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Cognito SDK for iOS' s.description = 'Amazon Cognito offers multi device data synchronization with offline access' @@ -13,7 +13,7 @@ Pod::Spec.new do |s| :tag => s.version} s.requires_arc = true s.library = 'sqlite3' - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSCognito/*.{h,m}', 'AWSCognito/**/*.{h,m}' s.public_header_files = 'AWSCognito/*.h', 'AWSCognito/CognitoSync/*.h' s.private_header_files = 'AWSCognito/Fabric/*.h', 'AWSCognito/Internal/*.h' diff --git a/AWSCognito/AWSCognitoService.m b/AWSCognito/AWSCognitoService.m index 7fff3ae67ba..a76d3a31f05 100644 --- a/AWSCognito/AWSCognitoService.m +++ b/AWSCognito/AWSCognitoService.m @@ -34,7 +34,7 @@ #import "Fabric+FABKits.h" static NSString *const AWSInfoCognito = @"Cognito"; -static NSString *const AWSCognitoSDKVersion = @"2.6.2"; +static NSString *const AWSCognitoSDKVersion = @"2.6.3"; NSString *const AWSCognitoDidStartSynchronizeNotification = @"com.amazon.cognito.AWSCognitoDidStartSynchronizeNotification"; NSString *const AWSCognitoDidEndSynchronizeNotification = @"com.amazon.cognito.AWSCognitoDidEndSynchronizeNotification"; diff --git a/AWSCognito/CognitoSync/AWSCognitoSyncService.m b/AWSCognito/CognitoSync/AWSCognitoSyncService.m index db60652954e..686e078f2e5 100644 --- a/AWSCognito/CognitoSync/AWSCognitoSyncService.m +++ b/AWSCognito/CognitoSync/AWSCognitoSyncService.m @@ -26,7 +26,7 @@ #import "AWSCognitoSyncResources.h" static NSString *const AWSInfoCognitoSync = @"CognitoSync"; -static NSString *const AWSCognitoSyncSDKVersion = @"2.6.2"; +static NSString *const AWSCognitoSyncSDKVersion = @"2.6.3"; @interface AWSCognitoSyncResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSCognito/Info.plist b/AWSCognito/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSCognito/Info.plist +++ b/AWSCognito/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSCognitoAuth.podspec b/AWSCognitoAuth.podspec index 3d12dcc2c60..2bfb54811e6 100644 --- a/AWSCognitoAuth.podspec +++ b/AWSCognitoAuth.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSCognitoAuth' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Cognito Auth SDK for iOS' s.description = 'Amazon Cognito Auth enables sign up and authentication of your end users via a hosted UI' diff --git a/AWSCognitoAuth/AWSCognitoAuth.m b/AWSCognitoAuth/AWSCognitoAuth.m index 99632ea7066..ef4cda954fd 100644 --- a/AWSCognitoAuth/AWSCognitoAuth.m +++ b/AWSCognitoAuth/AWSCognitoAuth.m @@ -41,7 +41,7 @@ @interface AWSCognitoAuth()CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSCognitoIdentityProvider.podspec b/AWSCognitoIdentityProvider.podspec index fd0aa18d6d6..f22fe00b4e4 100644 --- a/AWSCognitoIdentityProvider.podspec +++ b/AWSCognitoIdentityProvider.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSCognitoIdentityProvider' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Cognito Identity Provider SDK for iOS (Beta)' s.description = 'Amazon Cognito Identity Provider enables sign up and authentication of your end users' @@ -12,7 +12,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSCognitoIdentityProvider/**/*.{h,m,c}' s.public_header_files = 'AWSCognitoIdentityProvider/*.h', 'AWSCognitoIdentityProvider/CognitoIdentityProvider/*.h' s.private_header_files = 'AWSCognitoIdentityProvider/Internal/*.h' diff --git a/AWSCognitoIdentityProvider/CognitoIdentityProvider/AWSCognitoIdentityProviderService.m b/AWSCognitoIdentityProvider/CognitoIdentityProvider/AWSCognitoIdentityProviderService.m index ef0aa213ab2..d1f8f069f0f 100644 --- a/AWSCognitoIdentityProvider/CognitoIdentityProvider/AWSCognitoIdentityProviderService.m +++ b/AWSCognitoIdentityProvider/CognitoIdentityProvider/AWSCognitoIdentityProviderService.m @@ -26,7 +26,7 @@ #import "AWSCognitoIdentityProviderResources.h" static NSString *const AWSInfoCognitoIdentityProvider = @"CognitoIdentityProvider"; -static NSString *const AWSCognitoIdentityProviderSDKVersion = @"2.6.2"; +static NSString *const AWSCognitoIdentityProviderSDKVersion = @"2.6.3"; @interface AWSCognitoIdentityProviderResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSCognitoIdentityProvider/Info.plist b/AWSCognitoIdentityProvider/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSCognitoIdentityProvider/Info.plist +++ b/AWSCognitoIdentityProvider/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSCognitoSync.podspec b/AWSCognitoSync.podspec index 68b73bdb3a1..7f3afee1216 100644 --- a/AWSCognitoSync.podspec +++ b/AWSCognitoSync.podspec @@ -1,7 +1,7 @@ Pod::Spec.new do |s| s.name = 'AWSCognitoSync' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Cognito SDK for iOS' s.description = 'Amazon Cognito offers multi device data synchronization with offline access' @@ -14,7 +14,7 @@ Pod::Spec.new do |s| :tag => s.version} s.requires_arc = true s.library = 'sqlite3' - s.dependency 'AWSCognito', '2.6.2' + s.dependency 'AWSCognito', '2.6.3' s.deprecated = true s.deprecated_in_favor_of = 'AWSCognito' diff --git a/AWSCore.podspec b/AWSCore.podspec index 4473643593f..63d4e9296bf 100644 --- a/AWSCore.podspec +++ b/AWSCore.podspec @@ -1,7 +1,7 @@ Pod::Spec.new do |s| s.name = 'AWSCore' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' diff --git a/AWSCore/Info.plist b/AWSCore/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSCore/Info.plist +++ b/AWSCore/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSCore/Service/AWSService.m b/AWSCore/Service/AWSService.m index a0260e16718..c9e52330ed6 100644 --- a/AWSCore/Service/AWSService.m +++ b/AWSCore/Service/AWSService.m @@ -21,7 +21,7 @@ #import "AWSCocoaLumberjack.h" #import "AWSCategory.h" -NSString *const AWSiOSSDKVersion = @"2.6.2"; +NSString *const AWSiOSSDKVersion = @"2.6.3"; NSString *const AWSServiceErrorDomain = @"com.amazonaws.AWSServiceErrorDomain"; static NSString *const AWSServiceConfigurationUnknown = @"Unknown"; diff --git a/AWSDynamoDB.podspec b/AWSDynamoDB.podspec index a951fb8b7fc..df9816cca20 100644 --- a/AWSDynamoDB.podspec +++ b/AWSDynamoDB.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSDynamoDB' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSDynamoDB/*.{h,m}' end diff --git a/AWSDynamoDB/AWSDynamoDBService.m b/AWSDynamoDB/AWSDynamoDBService.m index 0c375d136bc..b5662c5f80e 100644 --- a/AWSDynamoDB/AWSDynamoDBService.m +++ b/AWSDynamoDB/AWSDynamoDBService.m @@ -27,7 +27,7 @@ #import "AWSDynamoDBRequestRetryHandler.h" static NSString *const AWSInfoDynamoDB = @"DynamoDB"; -static NSString *const AWSDynamoDBSDKVersion = @"2.6.2"; +static NSString *const AWSDynamoDBSDKVersion = @"2.6.3"; @interface AWSDynamoDBResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSDynamoDB/Info.plist b/AWSDynamoDB/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSDynamoDB/Info.plist +++ b/AWSDynamoDB/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSEC2.podspec b/AWSEC2.podspec index bc41ecdef8d..f043b7a8a6f 100644 --- a/AWSEC2.podspec +++ b/AWSEC2.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSEC2' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSEC2/*.{h,m}' end diff --git a/AWSEC2/AWSEC2Service.m b/AWSEC2/AWSEC2Service.m index e70cb1d5e91..3623549e2d4 100644 --- a/AWSEC2/AWSEC2Service.m +++ b/AWSEC2/AWSEC2Service.m @@ -27,7 +27,7 @@ #import "AWSEC2Serializer.h" static NSString *const AWSInfoEC2 = @"EC2"; -static NSString *const AWSEC2SDKVersion = @"2.6.2"; +static NSString *const AWSEC2SDKVersion = @"2.6.3"; @interface AWSEC2ResponseSerializer : AWSXMLResponseSerializer diff --git a/AWSEC2/Info.plist b/AWSEC2/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSEC2/Info.plist +++ b/AWSEC2/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSElasticLoadBalancing.podspec b/AWSElasticLoadBalancing.podspec index 432fc7ce271..1ba69bb13a4 100644 --- a/AWSElasticLoadBalancing.podspec +++ b/AWSElasticLoadBalancing.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSElasticLoadBalancing' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSElasticLoadBalancing/*.{h,m}' end diff --git a/AWSElasticLoadBalancing/AWSElasticLoadBalancingService.m b/AWSElasticLoadBalancing/AWSElasticLoadBalancingService.m index 81fd95a4989..0262d28d526 100644 --- a/AWSElasticLoadBalancing/AWSElasticLoadBalancingService.m +++ b/AWSElasticLoadBalancing/AWSElasticLoadBalancingService.m @@ -26,7 +26,7 @@ #import "AWSElasticLoadBalancingResources.h" static NSString *const AWSInfoElasticLoadBalancing = @"ElasticLoadBalancing"; -static NSString *const AWSElasticLoadBalancingSDKVersion = @"2.6.2"; +static NSString *const AWSElasticLoadBalancingSDKVersion = @"2.6.3"; @interface AWSElasticLoadBalancingResponseSerializer : AWSXMLResponseSerializer diff --git a/AWSElasticLoadBalancing/Info.plist b/AWSElasticLoadBalancing/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSElasticLoadBalancing/Info.plist +++ b/AWSElasticLoadBalancing/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSFacebookSignIn.podspec b/AWSFacebookSignIn.podspec index a32a227ee60..2654ac79de0 100644 --- a/AWSFacebookSignIn.podspec +++ b/AWSFacebookSignIn.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSFacebookSignIn' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,7 +12,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSAuthCore', '2.6.2' + s.dependency 'AWSAuthCore', '2.6.3' s.dependency 'FBSDKLoginKit', '~> 4.0' s.dependency 'FBSDKCoreKit', '~> 4.0' s.source_files = 'AWSAuthSDK/Sources/AWSFacebookSignIn/*.{h,m}' diff --git a/AWSGoogleSignIn.podspec b/AWSGoogleSignIn.podspec index 9d45570a809..5f43b2c096f 100644 --- a/AWSGoogleSignIn.podspec +++ b/AWSGoogleSignIn.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSGoogleSignIn' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,7 +12,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSAuthCore', '2.6.2' + s.dependency 'AWSAuthCore', '2.6.3' s.source_files = 'AWSAuthSDK/Sources/AWSGoogleSignIn/*.{h,m}', 'AWSAuthSDK/Dependencies/GoogleHeaders/*.h' s.public_header_files = 'AWSAuthSDK/Sources/AWSGoogleSignIn/*.h' s.private_header_files = 'AWSAuthSDK/Dependencies/GoogleHeaders/*.h' diff --git a/AWSIoT.podspec b/AWSIoT.podspec index e0ef4944150..e5d6c1350a4 100644 --- a/AWSIoT.podspec +++ b/AWSIoT.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSIoT' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,7 +12,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSIoT/*.{h,m}', 'AWSIoT/**/*.{h,m}' s.private_header_files = 'AWSIoT/Internal/*.h' end diff --git a/AWSIoT/AWSIoTDataService.m b/AWSIoT/AWSIoTDataService.m index 91eb81d3ba6..25d02d454ec 100644 --- a/AWSIoT/AWSIoTDataService.m +++ b/AWSIoT/AWSIoTDataService.m @@ -26,7 +26,7 @@ #import "AWSIoTDataResources.h" static NSString *const AWSInfoIoTData = @"IoTData"; -static NSString *const AWSIoTDataSDKVersion = @"2.6.2"; +static NSString *const AWSIoTDataSDKVersion = @"2.6.3"; @interface AWSIoTDataResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSIoT/AWSIoTService.m b/AWSIoT/AWSIoTService.m index a28291be68e..c87b99c4740 100644 --- a/AWSIoT/AWSIoTService.m +++ b/AWSIoT/AWSIoTService.m @@ -26,7 +26,7 @@ #import "AWSIoTResources.h" static NSString *const AWSInfoIoT = @"IoT"; -static NSString *const AWSIoTSDKVersion = @"2.6.2"; +static NSString *const AWSIoTSDKVersion = @"2.6.3"; @interface AWSIoTResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSIoT/Info.plist b/AWSIoT/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSIoT/Info.plist +++ b/AWSIoT/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSKMS.podspec b/AWSKMS.podspec index 45b9cc82ab3..fbe8833142f 100644 --- a/AWSKMS.podspec +++ b/AWSKMS.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSKMS' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSKMS/*.{h,m}' end diff --git a/AWSKMS/AWSKMSService.m b/AWSKMS/AWSKMSService.m index 02877b37566..63557044925 100644 --- a/AWSKMS/AWSKMSService.m +++ b/AWSKMS/AWSKMSService.m @@ -26,7 +26,7 @@ #import "AWSKMSResources.h" static NSString *const AWSInfoKMS = @"KMS"; -static NSString *const AWSKMSSDKVersion = @"2.6.2"; +static NSString *const AWSKMSSDKVersion = @"2.6.3"; @interface AWSKMSResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSKMS/Info.plist b/AWSKMS/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSKMS/Info.plist +++ b/AWSKMS/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSKinesis.podspec b/AWSKinesis.podspec index 5e275973921..5a4d8c0b1fe 100644 --- a/AWSKinesis.podspec +++ b/AWSKinesis.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSKinesis' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSKinesis/*.{h,m}' end diff --git a/AWSKinesis/AWSAbstractKinesisRecorder.h b/AWSKinesis/AWSAbstractKinesisRecorder.h index d9bd654199f..1a139160c53 100644 --- a/AWSKinesis/AWSAbstractKinesisRecorder.h +++ b/AWSKinesis/AWSAbstractKinesisRecorder.h @@ -50,8 +50,8 @@ /** Saves a record to local storage to be sent later. The record will be submitted to the streamName provided with a randomly generated partition key to ensure equal distribution across shards. - @param data The data to send to Amazon Kinesis. It needs to be smaller than 256KB. - @param streamName The stream name for Amazon Kinesis. + @param data The data to send to Amazon Kinesis. It needs to be smaller than 256KB. + @param streamName The stream name for Amazon Kinesis. @return AWSTask - task.result is always nil. */ diff --git a/AWSKinesis/AWSFirehoseService.m b/AWSKinesis/AWSFirehoseService.m index 79fae7c5425..3810e658706 100644 --- a/AWSKinesis/AWSFirehoseService.m +++ b/AWSKinesis/AWSFirehoseService.m @@ -26,7 +26,7 @@ #import "AWSFirehoseResources.h" static NSString *const AWSInfoFirehose = @"Firehose"; -static NSString *const AWSFirehoseSDKVersion = @"2.6.2"; +static NSString *const AWSFirehoseSDKVersion = @"2.6.3"; @interface AWSFirehoseResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSKinesis/AWSKinesisService.m b/AWSKinesis/AWSKinesisService.m index 603d27f0aeb..0760497a6bb 100644 --- a/AWSKinesis/AWSKinesisService.m +++ b/AWSKinesis/AWSKinesisService.m @@ -27,7 +27,7 @@ #import "AWSKinesisRequestRetryHandler.h" static NSString *const AWSInfoKinesis = @"Kinesis"; -static NSString *const AWSKinesisSDKVersion = @"2.6.2"; +static NSString *const AWSKinesisSDKVersion = @"2.6.3"; @interface AWSKinesisResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSKinesis/Info.plist b/AWSKinesis/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSKinesis/Info.plist +++ b/AWSKinesis/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSLambda.podspec b/AWSLambda.podspec index 30f68a155fc..9bdc368337d 100644 --- a/AWSLambda.podspec +++ b/AWSLambda.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSLambda' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSLambda/*.{h,m}' end diff --git a/AWSLambda/AWSLambdaService.m b/AWSLambda/AWSLambdaService.m index 34a5ff0e419..8d5f2bc9023 100644 --- a/AWSLambda/AWSLambdaService.m +++ b/AWSLambda/AWSLambdaService.m @@ -27,7 +27,7 @@ #import "AWSLambdaRequestRetryHandler.h" static NSString *const AWSInfoLambda = @"Lambda"; -static NSString *const AWSLambdaSDKVersion = @"2.6.2"; +static NSString *const AWSLambdaSDKVersion = @"2.6.3"; @interface AWSLambdaResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSLambda/Info.plist b/AWSLambda/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSLambda/Info.plist +++ b/AWSLambda/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSLex.podspec b/AWSLex.podspec index 52fb54a2743..f4f32556ca1 100644 --- a/AWSLex.podspec +++ b/AWSLex.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSLex' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,7 +12,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSLex/*.{h,m}', 'AWSLex/Bluefront/include/*.h' s.public_header_files = 'AWSLex/*.h' s.private_header_files = 'AWSLex/Bluefront/include/*.h' diff --git a/AWSLex/AWSLexInteractionKit.m b/AWSLex/AWSLexInteractionKit.m index 46721276df8..1507d51d956 100644 --- a/AWSLex/AWSLexInteractionKit.m +++ b/AWSLex/AWSLexInteractionKit.m @@ -22,7 +22,7 @@ #import NSString *const AWSInfoInteractionKit = @"LexInteractionKit"; -NSString *const AWSInteractionKitSDKVersion = @"2.6.2"; +NSString *const AWSInteractionKitSDKVersion = @"2.6.3"; NSString *const AWSInternalLexInteractionKit = @"LexInteractionKitClient"; NSString *const AWSLexInteractionKitUserAgent = @"interactionkit"; NSString *const AWSLexInteractionKitErrorDomain = @"com.amazonaws.AWSLexInteractionKitErrorDomain"; diff --git a/AWSLex/AWSLexService.m b/AWSLex/AWSLexService.m index d531b8d0fa2..f02cb22ad4a 100644 --- a/AWSLex/AWSLexService.m +++ b/AWSLex/AWSLexService.m @@ -28,7 +28,7 @@ #import "AWSLexSignature.h" static NSString *const AWSInfoLex = @"Lex"; -static NSString *const AWSLexSDKVersion = @"2.6.2"; +static NSString *const AWSLexSDKVersion = @"2.6.3"; @interface AWSLexResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSLex/Info.plist b/AWSLex/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSLex/Info.plist +++ b/AWSLex/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSLogs.podspec b/AWSLogs.podspec index 43771530b7e..7195fac7b5b 100644 --- a/AWSLogs.podspec +++ b/AWSLogs.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSLogs' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSLogs/*.{h,m}' end diff --git a/AWSLogs/AWSLogsService.m b/AWSLogs/AWSLogsService.m index f8d7e50f9d2..69c1c29be5f 100644 --- a/AWSLogs/AWSLogsService.m +++ b/AWSLogs/AWSLogsService.m @@ -26,7 +26,7 @@ #import "AWSLogsResources.h" static NSString *const AWSInfoLogs = @"Logs"; -static NSString *const AWSLogsSDKVersion = @"2.6.2"; +static NSString *const AWSLogsSDKVersion = @"2.6.3"; @interface AWSLogsResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSLogs/Info.plist b/AWSLogs/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSLogs/Info.plist +++ b/AWSLogs/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSMachineLearning.podspec b/AWSMachineLearning.podspec index fd24bc45deb..907afacf7fb 100644 --- a/AWSMachineLearning.podspec +++ b/AWSMachineLearning.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSMachineLearning' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSMachineLearning/*.{h,m}' end diff --git a/AWSMachineLearning/AWSMachineLearningService.m b/AWSMachineLearning/AWSMachineLearningService.m index 4034f514764..1b728d20b46 100644 --- a/AWSMachineLearning/AWSMachineLearningService.m +++ b/AWSMachineLearning/AWSMachineLearningService.m @@ -26,7 +26,7 @@ #import "AWSMachineLearningResources.h" static NSString *const AWSInfoMachineLearning = @"MachineLearning"; -static NSString *const AWSMachineLearningSDKVersion = @"2.6.2"; +static NSString *const AWSMachineLearningSDKVersion = @"2.6.3"; diff --git a/AWSMachineLearning/Info.plist b/AWSMachineLearning/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSMachineLearning/Info.plist +++ b/AWSMachineLearning/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSMobileAnalytics.podspec b/AWSMobileAnalytics.podspec index 7f4f89e81c8..ee08c0d1d25 100644 --- a/AWSMobileAnalytics.podspec +++ b/AWSMobileAnalytics.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSMobileAnalytics' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,7 +12,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSMobileAnalytics/*.{h,m}', 'AWSMobileAnalytics/**/*.{h,m}' s.private_header_files = 'AWSMobileAnalytics/Internal/*.h' end diff --git a/AWSMobileAnalytics/AWSMobileAnalyticsERS/AWSMobileAnalyticsERSService.m b/AWSMobileAnalytics/AWSMobileAnalyticsERS/AWSMobileAnalyticsERSService.m index 322ee63d288..a86391ab520 100644 --- a/AWSMobileAnalytics/AWSMobileAnalyticsERS/AWSMobileAnalyticsERSService.m +++ b/AWSMobileAnalytics/AWSMobileAnalyticsERS/AWSMobileAnalyticsERSService.m @@ -26,7 +26,7 @@ #import "AWSMobileAnalyticsERSResources.h" static NSString *const AWSInfoMobileAnalyticsERS = @"MobileAnalyticsERS"; -static NSString *const AWSMobileAnalyticsERSSDKVersion = @"2.6.2"; +static NSString *const AWSMobileAnalyticsERSSDKVersion = @"2.6.3"; @interface AWSMobileAnalyticsERSResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSMobileAnalytics/Info.plist b/AWSMobileAnalytics/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSMobileAnalytics/Info.plist +++ b/AWSMobileAnalytics/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSMobileAnalytics/Internal/AWSMobileAnalyticsDefaultFileManager.m b/AWSMobileAnalytics/Internal/AWSMobileAnalyticsDefaultFileManager.m index 43dcef367bf..c45152b04c3 100644 --- a/AWSMobileAnalytics/Internal/AWSMobileAnalyticsDefaultFileManager.m +++ b/AWSMobileAnalytics/Internal/AWSMobileAnalyticsDefaultFileManager.m @@ -676,8 +676,19 @@ -(BOOL) writeData:(id) theData } return NO; } + + NSString *stringFromData = [AWSMobileAnalyticsStringUtils dataToString:data]; + if(stringFromData == nil || stringFromData.length == 0) + { + if([theFile exists]) + { + NSError *deleteError = nil; + [self deleteFile:theFile error:&deleteError]; + } + return NO; + } - BOOL success = [theWriter writeLine:[AWSMobileAnalyticsStringUtils dataToString:data] error:&error]; + BOOL success = [theWriter writeLine:stringFromData error:&error]; if(error != nil || !success) { if(error != nil) diff --git a/AWSMobileAnalytics/Internal/AWSMobileAnalyticsWriter.m b/AWSMobileAnalytics/Internal/AWSMobileAnalyticsWriter.m index 3708b56d313..cd081f33e92 100644 --- a/AWSMobileAnalytics/Internal/AWSMobileAnalyticsWriter.m +++ b/AWSMobileAnalytics/Internal/AWSMobileAnalyticsWriter.m @@ -64,6 +64,10 @@ -(BOOL)write:(NSString*)stringToWrite error:(NSError**)writeError; -(BOOL)writeLine:(NSString*)stringToWrite error:(NSError**)writeError { + if(stringToWrite == nil || stringToWrite.length == 0) + { + return NO; + } // check if this already ends with newline NSString* suffix = [stringToWrite substringFromIndex:[stringToWrite length] - 1]; NSRange newlineOccurence = [suffix rangeOfCharacterFromSet:[NSCharacterSet newlineCharacterSet]]; diff --git a/AWSMobileAnalyticsLegacyTests/AIDefaultFileManagerTests.m b/AWSMobileAnalyticsLegacyTests/AIDefaultFileManagerTests.m index 5c70f4afed1..ae3291267bf 100644 --- a/AWSMobileAnalyticsLegacyTests/AIDefaultFileManagerTests.m +++ b/AWSMobileAnalyticsLegacyTests/AIDefaultFileManagerTests.m @@ -211,4 +211,15 @@ - (void)test_deleteFilesInVariousWaysAndThenListFilesInDir_correctListReturned [self.rootFile deleteFile]; } +- (void)test_createFileAndTryWritingEmptyData +{ + AWSMobileAnalyticsDefaultFileManager *fileManager = [[AWSMobileAnalyticsDefaultFileManager alloc] initWithFileManager:self.nsFileManager withRootFile:self.rootFile]; + NSError *error = nil; + AWSMobileAnalyticsFile *file = [fileManager createFileWithPath:[rootPath stringByAppendingPathComponent:@"emptyFileTest.txt"] error:&error]; + NSString *fileContent = @""; + BOOL result = [fileManager writeData:[fileContent dataUsingEncoding:NSUTF8StringEncoding] toFile:file withFormat:JSON withError:&error]; + XCTAssertFalse(result); + XCTAssertNil(error); +} + @end diff --git a/AWSPinpoint.podspec b/AWSPinpoint.podspec index ccd5b9e58d2..7751cb1ec1e 100644 --- a/AWSPinpoint.podspec +++ b/AWSPinpoint.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSPinpoint' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,7 +12,7 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSPinpoint/*.{h,m}', 'AWSPinpoint/**/*.{h,m}' s.private_header_files = 'AWSPinpoint/Internal/*.h' end diff --git a/AWSPinpoint/AWSPinpointAnalytics/AWSPinpointAnalyticsService.m b/AWSPinpoint/AWSPinpointAnalytics/AWSPinpointAnalyticsService.m index 3f7ffc6b841..415eaee0161 100644 --- a/AWSPinpoint/AWSPinpointAnalytics/AWSPinpointAnalyticsService.m +++ b/AWSPinpoint/AWSPinpointAnalytics/AWSPinpointAnalyticsService.m @@ -26,7 +26,7 @@ #import "AWSPinpointAnalyticsResources.h" static NSString *const AWSInfoPinpointAnalytics = @"PinpointAnalytics"; -static NSString *const AWSPinpointAnalyticsSDKVersion = @"2.6.2"; +static NSString *const AWSPinpointAnalyticsSDKVersion = @"2.6.3"; @interface AWSPinpointAnalyticsResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSPinpoint/AWSPinpointConfiguration.m b/AWSPinpoint/AWSPinpointConfiguration.m index 37612bf21b9..97a41c6cbee 100644 --- a/AWSPinpoint/AWSPinpointConfiguration.m +++ b/AWSPinpoint/AWSPinpointConfiguration.m @@ -45,6 +45,10 @@ -(instancetype) init { @end +@interface AWSPinpointConfiguration() +@property (nonatomic, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointConfiguration #pragma mark - Static Helpers - @@ -140,6 +144,7 @@ - (instancetype) initWithAppId:(NSString*) appId serviceConfiguration:(AWSServiceConfiguration*) analyticsServiceConfiguration targetingServiceConfiguration:(AWSServiceConfiguration*) targetingServiceConfiguration { if (self = [super init]) { + _userDefaults = [NSUserDefaults standardUserDefaults]; _debug = NO; _appId = (appId)? appId : [AWSPinpointConfiguration appId]; _launchOptions = launchOptions; diff --git a/AWSPinpoint/AWSPinpointEndpointProfile.m b/AWSPinpoint/AWSPinpointEndpointProfile.m index c105ff4a919..e85dd7552cd 100644 --- a/AWSPinpoint/AWSPinpointEndpointProfile.m +++ b/AWSPinpoint/AWSPinpointEndpointProfile.m @@ -46,10 +46,22 @@ - (instancetype) initWithApplicationId:(NSString*) applicationId endpointId:(NSString*) endpointId applicationLevelOptOut:(BOOL) applicationLevelOptOut debug:(BOOL) debug { + return [self initWithApplicationId:applicationId + endpointId:endpointId + applicationLevelOptOut:applicationLevelOptOut + debug:debug + userDefaults:[NSUserDefaults standardUserDefaults]]; +} + +- (instancetype) initWithApplicationId:(NSString*) applicationId + endpointId:(NSString*) endpointId + applicationLevelOptOut:(BOOL) applicationLevelOptOut + debug:(BOOL) debug + userDefaults:(NSUserDefaults*) userDefaults { if (self = [super init]) { //Remove spaces and brackets from token - NSString *deviceTokenString = [[[[[NSUserDefaults standardUserDefaults] objectForKey:AWSDeviceTokenKey] description] stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"<>"]] stringByReplacingOccurrencesOfString:@" " withString:@""]; - + NSString *deviceTokenString = [[[[userDefaults objectForKey:AWSDeviceTokenKey] description] stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"<>"]] stringByReplacingOccurrencesOfString:@" " withString:@""]; + _applicationId = applicationId; _endpointId = endpointId; _channelType = debug? DEBUG_CHANNEL_TYPE : CHANNEL_TYPE; @@ -72,7 +84,7 @@ - (instancetype)initWithApplicationId:(NSString*) applicationId - (instancetype)initWithContext:(AWSPinpointContext *) context { BOOL applicationLevelOptOut = [self isApplicationLevelOptOut:context]; - + return [self initWithApplicationId: context.configuration.appId endpointId:context.uniqueId applicationLevelOptOut:applicationLevelOptOut debug:context.configuration.debug]; } @@ -80,7 +92,7 @@ - (BOOL) isApplicationLevelOptOut:(AWSPinpointContext *) context { if (context.configuration.isApplicationLevelOptOut != NULL && context.configuration.isApplicationLevelOptOut() == YES){ return YES; } - + return NO; } diff --git a/AWSPinpoint/AWSPinpointEventRecorder.m b/AWSPinpoint/AWSPinpointEventRecorder.m index 58834fc0dd3..a4ba2235b8c 100644 --- a/AWSPinpoint/AWSPinpointEventRecorder.m +++ b/AWSPinpoint/AWSPinpointEventRecorder.m @@ -40,6 +40,8 @@ @interface AWSPinpointEventRecorder() @property (nonatomic, strong) AWSFMDatabaseQueue *databaseQueue; @property (nonatomic, strong) NSString *databasePath; @property (nonatomic, strong) AWSPinpointContext *context; +@property (nonatomic, strong) AWSPinpointEndpointProfile *profile; + @end @interface AWSPinpointSession() @@ -49,7 +51,7 @@ - (instancetype)initWithSessionId:(NSString *)sessionId - (UTCTimeMillis) timeDurationInMillis; @end -@interface AWSPinpointEvent () +@interface AWSPinpointEvent() @property (nonatomic, readwrite) AWSPinpointSession *session; -(instancetype)initWithEventType:(NSString*) theEventType eventTimestamp:(UTCTimeMillis) theEventTimestamp @@ -58,6 +60,10 @@ -(instancetype)initWithEventType:(NSString*) theEventType metrics:(NSMutableDictionary*) metrics; @end +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointEventRecorder - (instancetype)init { @@ -69,7 +75,8 @@ - (instancetype)init { - (instancetype)initWithContext:(AWSPinpointContext *) context { if (self = [super init]) { _context = context; - + _profile = [_context.targetingClient currentEndpointProfile]; + NSString *databaseDirectoryPath = [NSTemporaryDirectory() stringByAppendingPathComponent:AWSPinpointClientRecorderDatabasePathPrefix]; _databasePath = [databaseDirectoryPath stringByAppendingPathComponent:context.configuration.appId]; @@ -151,7 +158,7 @@ - (AWSPinpointSession *)validateOrRetrieveSession:(AWSPinpointSession *) session if (session && session.sessionId && session.sessionId.length >=1) { return session; } - NSData *sessionData = [[NSUserDefaults standardUserDefaults] dataForKey:AWSPinpointSessionKey]; + NSData *sessionData = [self.context.configuration.userDefaults dataForKey:AWSPinpointSessionKey]; AWSPinpointSession *previousSession; if (sessionData) { previousSession = [NSKeyedUnarchiver unarchiveObjectWithData:sessionData]; @@ -167,7 +174,7 @@ - (NSString *)validateOrRetrieveSessionId:(NSString *) sessionId { if(sessionId && sessionId.length >= 1) { return sessionId; } - NSData *sessionData = [[NSUserDefaults standardUserDefaults] dataForKey:AWSPinpointSessionKey]; + NSData *sessionData = [self.context.configuration.userDefaults dataForKey:AWSPinpointSessionKey]; if (sessionData) { AWSPinpointSession *previousSession = [NSKeyedUnarchiver unarchiveObjectWithData:sessionData]; sessionId = previousSession.sessionId; @@ -438,7 +445,7 @@ - (AWSTask*) getCurrentSession: (AWSPinpointSession*) session { NSString *fromQuery = @"FROM DirtyEvent "; NSString *orderQuery = @"ORDER BY timestamp ASC "; NSString *limitQuery = [NSString stringWithFormat:@"LIMIT %@", limit]; - + [databaseQueue inTransaction:^(AWSFMDatabase *db, BOOL *rollback) { AWSFMResultSet *rs = [db executeQuery:[NSString stringWithFormat:@"%@%@%@%@", selectQuery, fromQuery, orderQuery, limitQuery]]; if (!rs) { @@ -475,7 +482,8 @@ - (AWSTask*) getCurrentSession: (AWSPinpointSession*) session { - (AWSTask *> *)submitAllEvents { __block NSMutableArray *result = [NSMutableArray new]; __block AWSTask *returnTask; - + self.profile = [self.context.targetingClient currentEndpointProfile]; + [self getBatchRecords:^(NSArray *events, NSArray *eventIds, NSError *error) { returnTask = [self submitEvents:&result events:events eventIds:eventIds error:error]; }]; @@ -578,13 +586,11 @@ - (void) getBatchRecords:(void (^)(NSArray *events, NSArray *eventIds, NSError * return [[AWSTask taskWithResult:nil] continueWithExecutor:[AWSExecutor executorWithDispatchQueue:[AWSPinpointEventRecorder sharedQueue]] withSuccessBlock:^id _Nullable(AWSTask * _Nonnull task) { __block NSError *error = nil; - __block BOOL stop = NO; __block NSMutableArray *events = [NSMutableArray new]; - AWSTask *submitTask = [[self submitEvents:temporaryEvents - error:&error - eventIDs:eventIds - stop:&stop] + AWSTask *submitTask = [[self putEvents:temporaryEvents + error:&error + eventIDs:eventIds] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { if (task.error) { error = task.error; @@ -721,10 +727,9 @@ - (void)checkByteThresholdForNotification:(NSUInteger)notificationByteThreshold } } -- (AWSTask *)submitEvents:(NSArray *)temporaryEvents - error:(NSError* __autoreleasing *) error - eventIDs:(NSArray *)eventIDs - stop:(BOOL *)stop { +- (AWSTask *)putEvents:(NSArray *)temporaryEvents + error:(NSError* __autoreleasing *) error + eventIDs:(NSArray *)eventIDs { AWSFMDatabaseQueue *databaseQueue = self.databaseQueue; NSMutableArray *events = [NSMutableArray new]; @@ -750,9 +755,6 @@ - (AWSTask *)submitEvents:(NSArray *)temporaryEvents return [[self.context.analyticsService putEvents:putEventsInput] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { if (task.error) { AWSDDLogError(@"Error: [%@]", task.error); - if ([task.error.domain isEqualToString:NSURLErrorDomain]) { - *stop = YES; - } if ([task.error.domain isEqualToString:AWSPinpointAnalyticsErrorDomain] && (task.error.code == AWSPinpointAnalyticsErrorBadRequest || [task.error.userInfo[@"NSLocalizedFailureReason"] isEqualToString:@"ValidationException"]) ) { NSInteger responseCode = [task.error.userInfo[@"responseStatusCode"] integerValue]; @@ -826,7 +828,7 @@ - (AWSPinpointAnalyticsPutEventsInput*) putEventsInputForEvents:(NSArray*) event //Set endpoint in clientContext if pinpoint is enabled if (self.context.targetingService) { - NSDictionary *endpointCustomAttribute = [NSDictionary dictionaryWithObject:[[self.context.targetingClient currentEndpointProfile] description] forKey:@"endpoint"]; + NSDictionary *endpointCustomAttribute = [NSDictionary dictionaryWithObject:[self.profile description] forKey:@"endpoint"]; [self.context.clientContext setCustomAttributes:endpointCustomAttribute]; } putEventInput.clientContext = [self.context.clientContext JSONString]; diff --git a/AWSPinpoint/AWSPinpointNotificationManager.m b/AWSPinpoint/AWSPinpointNotificationManager.m index 2abbd8f426f..2e5d11bc6a2 100644 --- a/AWSPinpoint/AWSPinpointNotificationManager.m +++ b/AWSPinpoint/AWSPinpointNotificationManager.m @@ -21,6 +21,7 @@ #import "AWSPinpointService.h" #import "AWSPinpointEvent.h" #import "AWSPinpointContext.h" +#import "AWSPinpointConfiguration.h" static NSString *const AWSCampaignDeepLinkKey = @"deeplink"; static NSString *const AWSAttributeApplicationStateKey = @"applicationState"; @@ -41,6 +42,10 @@ @interface AWSPinpointAnalyticsClient() - (void) setCampaignAttributes:(NSDictionary*) campaign; @end +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointNotificationManager - (instancetype)init { @@ -93,12 +98,11 @@ - (BOOL)interceptDidFinishLaunchingWithOptions:(nullable NSDictionary *)launchOp } - (void)interceptDidRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken { - NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; //Check if device token has changed - NSData *currentToken = [userDefaults objectForKey:AWSDeviceTokenKey]; + NSData *currentToken = [self.context.configuration.userDefaults objectForKey:AWSDeviceTokenKey]; if (![currentToken isEqualToData:deviceToken]) { - [userDefaults setObject:deviceToken forKey:AWSDeviceTokenKey]; - [userDefaults synchronize]; + [self.context.configuration.userDefaults setObject:deviceToken forKey:AWSDeviceTokenKey]; + [self.context.configuration.userDefaults synchronize]; //Update endpoint AWSDDLogInfo(@"Calling endpoint Service to register token"); diff --git a/AWSPinpoint/AWSPinpointSessionClient.m b/AWSPinpoint/AWSPinpointSessionClient.m index 79f6de39e5f..d58dbcab133 100644 --- a/AWSPinpoint/AWSPinpointSessionClient.m +++ b/AWSPinpoint/AWSPinpointSessionClient.m @@ -77,6 +77,10 @@ - (void)setCampaignAttributes:(NSDictionary*) campaign; @end +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + #pragma mark - AWSPinpointSessionClient - @implementation AWSPinpointSessionClient @@ -90,7 +94,7 @@ - (instancetype)initWithContext:(AWSPinpointContext *)context { NSAssert(context != nil, @"context should not have been nil"); if (self = [super init]) { _context = context; - NSData *sessionData = [[NSUserDefaults standardUserDefaults] dataForKey:AWSPinpointSessionKey]; + NSData *sessionData = [context.configuration.userDefaults dataForKey:AWSPinpointSessionKey]; _session = [NSKeyedUnarchiver unarchiveObjectWithData:sessionData]; //Only add observers if auto session recording is enabled @@ -122,9 +126,8 @@ - (void)saveSession { @synchronized (_session) { AWSPinpointSession *session = [_session copy]; NSData *sessionData = [NSKeyedArchiver archivedDataWithRootObject:session]; - [[NSUserDefaults standardUserDefaults] setObject:sessionData forKey:AWSPinpointSessionKey]; - [[NSUserDefaults standardUserDefaults] synchronize]; - + [self.context.configuration.userDefaults setObject:sessionData forKey:AWSPinpointSessionKey]; + [self.context.configuration.userDefaults synchronize]; } } @catch (NSException *e) { diff --git a/AWSPinpoint/AWSPinpointTargeting/AWSPinpointTargetingService.m b/AWSPinpoint/AWSPinpointTargeting/AWSPinpointTargetingService.m index 8c999b3fe0b..45f962ab66a 100644 --- a/AWSPinpoint/AWSPinpointTargeting/AWSPinpointTargetingService.m +++ b/AWSPinpoint/AWSPinpointTargeting/AWSPinpointTargetingService.m @@ -26,7 +26,7 @@ #import "AWSPinpointTargetingResources.h" static NSString *const AWSInfoPinpointTargeting = @"PinpointTargeting"; -static NSString *const AWSPinpointTargetingSDKVersion = @"2.6.2"; +static NSString *const AWSPinpointTargetingSDKVersion = @"2.6.3"; @interface AWSPinpointTargetingResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSPinpoint/AWSPinpointTargetingClient.m b/AWSPinpoint/AWSPinpointTargetingClient.m index 0e3f95097fc..cb994300df9 100644 --- a/AWSPinpoint/AWSPinpointTargetingClient.m +++ b/AWSPinpoint/AWSPinpointTargetingClient.m @@ -35,6 +35,10 @@ @interface AWSPinpointTargetingClient() @end +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointTargetingClient - (instancetype)init { @@ -46,9 +50,9 @@ - (instancetype)init { - (instancetype)initWithContext:(AWSPinpointContext *) context { if (self = [super init]) { _context = context; - NSDictionary *customAttributes = [[NSUserDefaults standardUserDefaults] objectForKey:AWSPinpointEndpointAttributesKey]; + NSDictionary *customAttributes = [context.configuration.userDefaults objectForKey:AWSPinpointEndpointAttributesKey]; _globalAttributes = [[NSMutableDictionary alloc] initWithDictionary:customAttributes]; - NSDictionary *customMetrics = [[NSUserDefaults standardUserDefaults] objectForKey:AWSPinpointEndpointMetricsKey]; + NSDictionary *customMetrics = [context.configuration.userDefaults objectForKey:AWSPinpointEndpointMetricsKey]; _globalMetrics = [[NSMutableDictionary alloc] initWithDictionary:customMetrics]; } @@ -139,9 +143,8 @@ - (void)addAttribute:(NSArray *)theValue @synchronized(self) { //Save value to disk [self.globalAttributes setValue:theValue forKey:theKey]; - NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; - [userDefaults setObject:self.globalAttributes forKey:AWSPinpointEndpointAttributesKey]; - [userDefaults synchronize]; + [self.context.configuration.userDefaults setObject:self.globalAttributes forKey:AWSPinpointEndpointAttributesKey]; + [self.context.configuration.userDefaults synchronize]; } } @@ -154,9 +157,8 @@ - (void)removeAttributeForKey:(NSString *) theKey { @synchronized(self) { [self.globalAttributes removeObjectForKey:theKey]; - NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; - [userDefaults setObject:self.globalAttributes forKey:AWSPinpointEndpointAttributesKey]; - [userDefaults synchronize]; + [self.context.configuration.userDefaults setObject:self.globalAttributes forKey:AWSPinpointEndpointAttributesKey]; + [self.context.configuration.userDefaults synchronize]; } } @@ -177,9 +179,8 @@ - (void)addMetric:(NSNumber *)theValue @synchronized(self) { [self.globalMetrics setValue:theValue forKey:theKey]; - NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; - [userDefaults setObject:self.globalMetrics forKey:AWSPinpointEndpointMetricsKey]; - [userDefaults synchronize]; + [self.context.configuration.userDefaults setObject:self.globalMetrics forKey:AWSPinpointEndpointMetricsKey]; + [self.context.configuration.userDefaults synchronize]; } } @@ -192,9 +193,8 @@ - (void)removeMetricForKey:(NSString *) theKey { @synchronized(self) { [self.globalMetrics removeObjectForKey:theKey]; - NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; - [userDefaults setObject:self.globalMetrics forKey:AWSPinpointEndpointMetricsKey]; - [userDefaults synchronize]; + [self.context.configuration.userDefaults setObject:self.globalMetrics forKey:AWSPinpointEndpointMetricsKey]; + [self.context.configuration.userDefaults synchronize]; } } diff --git a/AWSPinpoint/Info.plist b/AWSPinpoint/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSPinpoint/Info.plist +++ b/AWSPinpoint/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSPinpoint/Internal/AWSPinpointContext.m b/AWSPinpoint/Internal/AWSPinpointContext.m index b9118204a17..013c7964ab0 100644 --- a/AWSPinpoint/Internal/AWSPinpointContext.m +++ b/AWSPinpoint/Internal/AWSPinpointContext.m @@ -37,6 +37,10 @@ @interface AWSPinpointContext () @end +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointClientContext - (NSDictionary *)dictionaryRepresentation { @@ -110,16 +114,16 @@ - (NSString *) retrieveUniqueId { AWSDDLogVerbose(@"Fallback: merge UniqueId to NSUserDefaults: %@", deviceUniqueId); //Failed to save to Keychain, fallback to NSUserDefaults deviceUniqueId = legacyUniqueId; - [[NSUserDefaults standardUserDefaults] setObject:deviceUniqueId forKey:AWSPinpointContextKeychainUniqueIdKey]; - [[NSUserDefaults standardUserDefaults] synchronize]; + [self.configuration.userDefaults setObject:deviceUniqueId forKey:AWSPinpointContextKeychainUniqueIdKey]; + [self.configuration.userDefaults synchronize]; //Delete old file if ([self removeLegacyFileWithConfiguration:self.configuration]) { AWSDDLogVerbose(@"Cannot remove legacy preferences file."); } } } else { - if ([[NSUserDefaults standardUserDefaults] stringForKey:AWSPinpointContextKeychainUniqueIdKey]) { - deviceUniqueId = [[NSUserDefaults standardUserDefaults] stringForKey:AWSPinpointContextKeychainUniqueIdKey]; + if ([self.configuration.userDefaults stringForKey:AWSPinpointContextKeychainUniqueIdKey]) { + deviceUniqueId = [self.configuration.userDefaults stringForKey:AWSPinpointContextKeychainUniqueIdKey]; //Try and resave to Keychain static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ @@ -129,9 +133,9 @@ - (NSString *) retrieveUniqueId { if ([self.keychain stringForKey:AWSPinpointContextKeychainUniqueIdKey]) { AWSDDLogVerbose(@"Merged Pinpoint UniqueId to Keychain: %@", deviceUniqueId); //Successful save to keychain, delete from UserDefaults - [[NSUserDefaults standardUserDefaults] setObject:nil forKey:AWSPinpointContextKeychainUniqueIdKey]; - [[NSUserDefaults standardUserDefaults] removeObjectForKey:AWSPinpointContextKeychainUniqueIdKey]; - [[NSUserDefaults standardUserDefaults] synchronize]; + [self.configuration.userDefaults setObject:nil forKey:AWSPinpointContextKeychainUniqueIdKey]; + [self.configuration.userDefaults removeObjectForKey:AWSPinpointContextKeychainUniqueIdKey]; + [self.configuration.userDefaults synchronize]; } } else { //Create new ID @@ -148,8 +152,8 @@ - (NSString *) retrieveUniqueId { AWSDDLogVerbose(@"Fallback: created new Pinpoint UniqueId and saved to NSUserDefaults: %@", deviceUniqueId); //Fallback to save to UserDefaults deviceUniqueId = [[NSUUID UUID] UUIDString]; - [[NSUserDefaults standardUserDefaults] setObject:deviceUniqueId forKey:AWSPinpointContextKeychainUniqueIdKey]; - [[NSUserDefaults standardUserDefaults] synchronize]; + [self.configuration.userDefaults setObject:deviceUniqueId forKey:AWSPinpointContextKeychainUniqueIdKey]; + [self.configuration.userDefaults synchronize]; } } } @@ -162,7 +166,6 @@ - (AWSPinpointContext *) initWithConfiguration:(AWSPinpointConfiguration *) conf _configuration = configuration; _keychain = [AWSUICKeyChainStore keyChainStoreWithService:AWSPinpointContextKeychainService]; _uniqueId = [self retrieveUniqueId]; - AWSPinpointEnvironment *environment = configuration.environment; _clientContext = [AWSPinpointClientContext new]; _clientContext.appVersion = environment.appVersion; diff --git a/AWSPinpointTests/AWSPinpointAnalyticsClientTests.m b/AWSPinpointTests/AWSPinpointAnalyticsClientTests.m index c708af7ee30..f0c130cd226 100644 --- a/AWSPinpointTests/AWSPinpointAnalyticsClientTests.m +++ b/AWSPinpointTests/AWSPinpointAnalyticsClientTests.m @@ -17,18 +17,27 @@ #import "AWSTestUtility.h" #import "AWSPinpoint.h" #import "OCMock.h" +#import "AWSPinpointContext.h" NSString *const AWSPinpointAnalyticsClientErrorDomain = @"com.amazonaws.AWSPinpointAnalyticsClientErrorDomain"; @interface AWSPinpointAnalyticsClientTests : XCTestCase @property (nonatomic, strong) AWSPinpoint *pinpoint; +@property (nonatomic, strong) NSUserDefaults *userDefaults; @end + +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointAnalyticsClientTests - (void)setUp { [super setUp]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointAnalyticsClientTests"]; + self.userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"AWSPinpointAnalyticsClientTests"]; [AWSTestUtility setupCognitoCredentialsProvider]; @@ -38,8 +47,10 @@ - (void)setUp { options:NSJSONReadingMutableContainers error:nil]; AWSPinpointConfiguration *configuration = [[AWSPinpointConfiguration alloc] initWithAppId:credentialsJson[@"pinpointAppId"] launchOptions:@{}]; - + configuration.userDefaults = self.userDefaults; + self.pinpoint = [AWSPinpoint pinpointWithConfiguration:configuration]; + [self.pinpoint.analyticsClient.eventRecorder removeAllEvents]; } diff --git a/AWSPinpointTests/AWSPinpointContextTests.m b/AWSPinpointTests/AWSPinpointContextTests.m index 04bf60d68c3..4c460e7a509 100644 --- a/AWSPinpointTests/AWSPinpointContextTests.m +++ b/AWSPinpointTests/AWSPinpointContextTests.m @@ -31,14 +31,23 @@ - (NSString *) retrieveUniqueId; @interface AWSPinpointContextTests : XCTestCase @property (nonatomic, strong) AWSPinpointConfiguration *configuration; +@property (nonatomic, strong) NSUserDefaults *userDefaults; @end +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointContextTests - (void)setUp { [super setUp]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointContextTests"]; + self.userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"AWSPinpointContextTests"]; + self.configuration = [[AWSPinpointConfiguration alloc] initWithAppId:@"AWSPinpointContextTests" launchOptions:nil]; + self.configuration.userDefaults = self.userDefaults; AWSUICKeyChainStore *keychain = [AWSUICKeyChainStore keyChainStoreWithService:AWSPinpointContextKeychainService]; [keychain removeAllItems]; } @@ -52,16 +61,19 @@ - (void)testConstructor { AWSPinpointContext *context = [AWSPinpointContext contextWithConfiguration:self.configuration]; XCTAssertNotNil(context); XCTAssertNotNil(context.clientContext); + XCTAssertNotNil(context.configuration.userDefaults); XCTAssertNotNil(context.uniqueId); XCTAssertNotNil(context.configuration); XCTAssertEqual(context.configuration, self.configuration); XCTAssertNil(context.analyticsService); XCTAssertNil(context.targetingService); - + XCTAssertTrue([context.configuration.userDefaults isEqual:self.userDefaults]); XCTAssertTrue([[context retrieveUniqueId] isEqualToString:context.uniqueId]); } - (void)testUniqueIdGeneration { + XCTestExpectation *expectation = [self expectationWithDescription:@"Test finished running."]; + AWSPinpointContext *context = [AWSPinpointContext contextWithConfiguration:self.configuration]; XCTAssertNotNil(context); XCTAssertNotNil(context.clientContext); @@ -85,25 +97,22 @@ - (void)testUniqueIdGeneration { //UniqueId should Match XCTAssertTrue([secondContext.uniqueId isEqualToString:context.uniqueId]); - //Remove uniqueId, new context should have new Id - AWSUICKeyChainStore *keychain = [AWSUICKeyChainStore keyChainStoreWithService:AWSPinpointContextKeychainService]; - [keychain removeAllItems]; - dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{ - //Remove from keychain as tests currently dont support the keychain - [[NSUserDefaults standardUserDefaults] removeObjectForKey:AWSPinpointContextKeychainUniqueIdKey]; - [[NSUserDefaults standardUserDefaults] synchronize]; - XCTAssertNil([[NSUserDefaults standardUserDefaults] stringForKey:AWSPinpointContextKeychainUniqueIdKey]); - - AWSPinpointContext *thirdContext = [AWSPinpointContext contextWithConfiguration:self.configuration]; - XCTAssertNotNil(thirdContext); - XCTAssertNotNil(thirdContext.clientContext); - XCTAssertNotNil(thirdContext.uniqueId); - XCTAssertNotNil(thirdContext.configuration); - XCTAssertEqual(thirdContext.configuration, self.configuration); - XCTAssertNil(thirdContext.analyticsService); - XCTAssertNil(thirdContext.targetingService); - XCTAssertFalse([thirdContext.uniqueId isEqualToString:context.uniqueId]); - }); + //New context should have new Id with new default suite + self.configuration.userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"testUniqueIdGeneration"]; + AWSPinpointContext *thirdContext = [AWSPinpointContext contextWithConfiguration:self.configuration]; + XCTAssertNotNil(thirdContext); + XCTAssertNotNil(thirdContext.clientContext); + XCTAssertNotNil(thirdContext.uniqueId); + XCTAssertNotNil(thirdContext.configuration); + XCTAssertEqual(thirdContext.configuration, self.configuration); + XCTAssertNil(thirdContext.analyticsService); + XCTAssertNil(thirdContext.targetingService); + XCTAssertFalse([thirdContext.uniqueId isEqualToString:context.uniqueId]); + [expectation fulfill]; + + [self waitForExpectationsWithTimeout:5 handler:^(NSError * _Nullable error) { + XCTAssertNil(error); + }]; } - (void)testUniqueIdLegacyMerge { @@ -151,7 +160,7 @@ - (void)testUniqueIdLegacyMerge { if ([keychain stringForKey:AWSPinpointContextKeychainUniqueIdKey]) { XCTAssertTrue([[keychain stringForKey:AWSPinpointContextKeychainUniqueIdKey] isEqualToString:context.uniqueId]); } else { //Check user defaults - XCTAssertTrue([[[NSUserDefaults standardUserDefaults] stringForKey:AWSPinpointContextKeychainUniqueIdKey] isEqualToString:context.uniqueId]); + XCTAssertTrue([[self.userDefaults stringForKey:AWSPinpointContextKeychainUniqueIdKey] isEqualToString:context.uniqueId]); } //Check if file got deleted @@ -176,7 +185,7 @@ - (void)testUniqueIdFallbackKeychainFail { XCTAssertEqual(context.configuration, self.configuration); XCTAssertNil(context.analyticsService); XCTAssertNil(context.targetingService); - XCTAssertTrue([context.uniqueId isEqualToString:[[NSUserDefaults standardUserDefaults] stringForKey:AWSPinpointContextKeychainUniqueIdKey]]); + XCTAssertTrue([context.uniqueId isEqualToString:[self.userDefaults stringForKey:AWSPinpointContextKeychainUniqueIdKey]]); } @end diff --git a/AWSPinpointTests/AWSPinpointEventRecorderTests.m b/AWSPinpointTests/AWSPinpointEventRecorderTests.m index 949858e5002..76bd7fd9730 100644 --- a/AWSPinpointTests/AWSPinpointEventRecorderTests.m +++ b/AWSPinpointTests/AWSPinpointEventRecorderTests.m @@ -19,6 +19,7 @@ #import #import "AWSPinpoint.h" #import "AWSTestUtility.h" +#import "AWSPinpointContext.h" NSString *const AWSKinesisRecorderTestStream = @"AWSSDKForiOSv2Test"; NSString *const AWSPinpointSessionKey = @"com.amazonaws.AWSPinpointSessionKey"; @@ -27,7 +28,6 @@ @interface AWSPinpoint() @property (nonatomic, strong) AWSPinpointContext *pinpointContext; - @end @@ -41,6 +41,7 @@ -(instancetype)initWithEventType:(NSString*) theEventType @interface AWSPinpointEventRecorderTests : XCTestCase @property (nonatomic, strong) AWSPinpoint *pinpoint; +@property (nonatomic, strong) NSUserDefaults *userDefaults; @end @@ -60,12 +61,23 @@ - (instancetype)initWithSessionId:(NSString *)sessionId withStopTime:(NSDate *)stopTime; @end +@interface AWSPinpointAnalyticsClient() +- (void) removeAllGlobalCampaignAttributes; +@end + +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointEventRecorderTests - (void)setUp { [super setUp]; [AWSTestUtility setupCognitoCredentialsProvider]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointEventRecorderTests"]; + self.userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"AWSPinpointEventRecorderTests"]; + NSString *filePath = [[NSBundle bundleForClass:[self class]] pathForResource:@"credentials" ofType:@"json"]; NSDictionary *credentialsJson = [NSJSONSerialization JSONObjectWithData:[NSData dataWithContentsOfFile:filePath] @@ -73,6 +85,9 @@ - (void)setUp { error:nil]; AWSPinpointConfiguration *config = [[AWSPinpointConfiguration alloc] initWithAppId:credentialsJson[@"pinpointAppId"] launchOptions:@{}]; + + config.userDefaults = self.userDefaults; + self.pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [[self.pinpoint.analyticsClient.eventRecorder removeAllEvents] waitUntilFinished]; [[AWSDDLog sharedInstance] setLogLevel:AWSDDLogLevelVerbose]; @@ -82,6 +97,105 @@ - (void)tearDown { [super tearDown]; } +- (void) clearSession { + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointEventRecorderTests"]; + [self.userDefaults setObject:nil forKey:AWSPinpointSessionKey]; + [self.userDefaults removeObjectForKey:AWSPinpointSessionKey]; + [self.userDefaults synchronize]; + + NSData *data = [self.userDefaults dataForKey:AWSPinpointSessionKey]; + AWSPinpointSession *session = [NSKeyedUnarchiver unarchiveObjectWithData:data]; + + NSLog(@"Session Object Should be Empty: %@",session.description); + + XCTAssertNil([self.userDefaults dataForKey:AWSPinpointSessionKey]); +} + +- (void) testEventsWithNoSessionId { + __block XCTestExpectation *expectation = [self expectationWithDescription:@"Test finished running."]; + AWSPinpointConfiguration *config = [[AWSPinpointConfiguration alloc] initWithAppId:@"testEventsWithNoSessionId" + launchOptions:nil + maxStorageSize:5*1024*1024 + sessionTimeout:0]; + config.enableAutoSessionRecording = NO; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"testEventsWithNoSessionId"]; + config.userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"testEventsWithNoSessionId"]; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; + [config.userDefaults setObject:nil forKey:AWSPinpointSessionKey]; + [config.userDefaults removeObjectForKey:AWSPinpointSessionKey]; + [config.userDefaults synchronize]; + [[pinpoint.analyticsClient.eventRecorder removeAllEvents] waitUntilFinished]; + + AWSPinpointEvent *event1 = [[AWSPinpointEvent alloc] initWithEventType:@"TEST" + eventTimestamp:123 + session:[[AWSPinpointSession alloc] initWithSessionId:nil withStartTime:[NSDate date] withStopTime:[NSDate date]] + attributes:nil + metrics:nil]; + // Test for default session id + [[[pinpoint.analyticsClient.eventRecorder saveEvent:event1] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + AWSPinpointEvent *taskEvent = task.result; + XCTAssertNotNil(taskEvent.session.sessionId); + XCTAssertTrue([DEFAULT_SESSION_ID isEqualToString:taskEvent.session.sessionId]); + XCTAssertNil(task.error); + return nil; + }] waitUntilFinished]; + __block AWSPinpointEvent *startEvent; + __block AWSPinpointEvent *stopEvent; + [[[pinpoint.sessionClient startSession] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + startEvent = task.result; + XCTAssertTrue([startEvent.eventType isEqualToString:@"_session.start"]); + XCTAssertTrue(startEvent.eventTimestamp > 0); + XCTAssertNotNil(startEvent.allAttributes); + XCTAssertEqual([startEvent.allAttributes count], 0); + XCTAssertNotNil(startEvent.session); + XCTAssertNotNil(startEvent.session.sessionId); + XCTAssertNotNil(startEvent.session.startTime); + XCTAssertNotNil(startEvent.allMetrics); + XCTAssertEqual([startEvent.allMetrics count], 0); + return nil; + }] waitUntilFinished]; + + [[[pinpoint.sessionClient stopSession] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + stopEvent = task.result; + XCTAssertTrue([stopEvent.eventType isEqualToString:@"_session.stop"]); + XCTAssertTrue(stopEvent.eventTimestamp > 0); + XCTAssertNotNil(stopEvent.allAttributes); + XCTAssertEqual([stopEvent.allAttributes count], 0); + XCTAssertNotNil(stopEvent.session); + XCTAssertNotNil(stopEvent.session.sessionId); + XCTAssertNotNil(stopEvent.session.startTime); + XCTAssertNotNil(stopEvent.session.stopTime); + XCTAssertNotNil(stopEvent.allMetrics); + XCTAssertEqual([stopEvent.allMetrics count], 0); + return nil; + }] waitUntilFinished]; + NSUserDefaults *userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"testEventsWithNoSessionId"]; + //Tests that session info is not deleted from userdefaults + XCTAssertNotNil([userDefaults dataForKey:AWSPinpointSessionKey]); + NSData *sessionData = [userDefaults dataForKey:AWSPinpointSessionKey]; + AWSPinpointSession *previousSession = [NSKeyedUnarchiver unarchiveObjectWithData:sessionData]; + NSString *sessionId = previousSession.sessionId; + + AWSPinpointEvent *event2 = [[AWSPinpointEvent alloc] initWithEventType:@"TEST" + eventTimestamp:123 + session:[[AWSPinpointSession alloc] initWithSessionId:nil withStartTime:[NSDate date] withStopTime:[NSDate date]] + attributes:nil + metrics:nil]; + // Check if the session id matches the one in the user defaults. + [[pinpoint.analyticsClient.eventRecorder saveEvent:event2] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + AWSPinpointEvent *taskEvent = task.result; + XCTAssertNotNil(taskEvent.session.sessionId); + XCTAssertTrue([sessionId isEqualToString:taskEvent.session.sessionId]); + XCTAssertNil(task.error); + [expectation fulfill]; + return nil; + }]; + + [self waitForExpectationsWithTimeout:5 handler:^(NSError * _Nullable error) { + XCTAssertNil(error); + }]; +} + - (void)testConstructors { @try { AWSPinpointEventRecorder *eventRecorder = [AWSPinpointEventRecorder new]; @@ -130,40 +244,97 @@ - (void) testDeleteAllDirtyEvents { }]; } -- (void) testUpdateSessionCampaignAttributes { - [[self.pinpoint.sessionClient startSession] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { +- (void) testUpdateSessionCampaignAttributesNoSession { + __block XCTestExpectation *expectation = [self expectationWithDescription:@"Test finished running."]; + + [[self.pinpoint.sessionClient stopSession] waitUntilFinished]; + + [[self.pinpoint.analyticsClient.eventRecorder updateSessionStartWithCampaignAttributes:@{@"campaignAttrKey":@"campaignAttrVal"}] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { [[self.pinpoint.analyticsClient.eventRecorder getCurrentSession:self.pinpoint.sessionClient.session] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { XCTAssertNotNil(task.result); XCTAssertTrue([task.result isKindOfClass:[AWSPinpointEvent class]]); AWSPinpointEvent *sessionStartResult = task.result; XCTAssertTrue([sessionStartResult.eventType isEqualToString:@"_session.start"]); XCTAssertTrue([sessionStartResult.session.sessionId isEqualToString:self.pinpoint.sessionClient.session.sessionId]); - XCTAssertTrue([sessionStartResult.session.startTime isEqualToDate:self.pinpoint.sessionClient.session.startTime]); - XCTAssertEqual(sessionStartResult.allAttributes.count, 0); + XCTAssertTrue([sessionStartResult.session.startTime.description isEqualToString:self.pinpoint.sessionClient.session.startTime.description]); + XCTAssertEqual(sessionStartResult.allAttributes.count, 1); + XCTAssertTrue([sessionStartResult.allAttributes[@"campaignAttrKey"] isEqualToString:@"campaignAttrVal"]); + [expectation fulfill]; + return nil; }]; return nil; }]; - [[self.pinpoint.analyticsClient.eventRecorder updateSessionStartWithCampaignAttributes:@{@"campaignAttrKey":@"campaignAttrVal"}] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { - [[self.pinpoint.analyticsClient.eventRecorder getCurrentSession:self.pinpoint.sessionClient.session] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + [self waitForExpectationsWithTimeout:5 handler:^(NSError * _Nullable error) { + XCTAssertNil(error); + }]; +} + + +- (void) testUpdateSessionCampaignAttributes { + __block XCTestExpectation *expectation = [self expectationWithDescription:@"Test finished running."]; + [self clearSession]; + + AWSPinpointConfiguration *config = [[AWSPinpointConfiguration alloc] initWithAppId:@"testUpdateSessionCampaignAttributes" launchOptions:@{}]; + + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"testUpdateSessionCampaignAttributes"]; + config.userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"testUpdateSessionCampaignAttributes"]; + + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; + [pinpoint.sessionClient stopSession]; + [pinpoint.analyticsClient removeAllGlobalCampaignAttributes]; + [[pinpoint.analyticsClient.eventRecorder removeAllEvents] waitUntilFinished]; + + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"testUpdateSessionCampaignAttributes"]; + [self.userDefaults setObject:nil forKey:AWSPinpointSessionKey]; + [self.userDefaults removeObjectForKey:AWSPinpointSessionKey]; + [self.userDefaults synchronize]; + + NSData *data = [self.userDefaults dataForKey:AWSPinpointSessionKey]; + AWSPinpointSession *session = [NSKeyedUnarchiver unarchiveObjectWithData:data]; + + NSLog(@"Session Object Should be Empty: %@",session.description); + + XCTAssertNil([self.userDefaults dataForKey:AWSPinpointSessionKey]); + + [[pinpoint.sessionClient startSession] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + [[pinpoint.analyticsClient.eventRecorder getCurrentSession:self.pinpoint.sessionClient.session] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { XCTAssertNotNil(task.result); XCTAssertTrue([task.result isKindOfClass:[AWSPinpointEvent class]]); AWSPinpointEvent *sessionStartResult = task.result; XCTAssertTrue([sessionStartResult.eventType isEqualToString:@"_session.start"]); - XCTAssertTrue([sessionStartResult.session.sessionId isEqualToString:self.pinpoint.sessionClient.session.sessionId]); - XCTAssertTrue([sessionStartResult.session.startTime isEqualToDate:self.pinpoint.sessionClient.session.startTime]); - XCTAssertEqual(sessionStartResult.allAttributes.count, 1); - XCTAssertTrue([sessionStartResult.allAttributes[@"campaignAttrKey"] isEqualToString:@"campaignAttrVal"]); + XCTAssertTrue([sessionStartResult.session.sessionId isEqualToString:pinpoint.sessionClient.session.sessionId]); + XCTAssertTrue([sessionStartResult.session.startTime.description isEqualToString:pinpoint.sessionClient.session.startTime.description]); + XCTAssertEqual(sessionStartResult.allAttributes.count, 0); + + [[pinpoint.analyticsClient.eventRecorder updateSessionStartWithCampaignAttributes:@{@"campaignAttrKey":@"campaignAttrVal"}] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + [[pinpoint.analyticsClient.eventRecorder getCurrentSession:self.pinpoint.sessionClient.session] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + XCTAssertNotNil(task.result); + XCTAssertTrue([task.result isKindOfClass:[AWSPinpointEvent class]]); + AWSPinpointEvent *sessionStartResult = task.result; + XCTAssertTrue([sessionStartResult.eventType isEqualToString:@"_session.start"]); + XCTAssertTrue([sessionStartResult.session.sessionId isEqualToString:pinpoint.sessionClient.session.sessionId]); + XCTAssertTrue([sessionStartResult.session.startTime.description isEqualToString:pinpoint.sessionClient.session.startTime.description]); + XCTAssertEqual(sessionStartResult.allAttributes.count, 1); + XCTAssertTrue([sessionStartResult.allAttributes[@"campaignAttrKey"] isEqualToString:@"campaignAttrVal"]); + [expectation fulfill]; + + return nil; + }]; + return nil; + }]; + return nil; }]; return nil; }]; - + [self waitForExpectationsWithTimeout:5 handler:^(NSError * _Nullable error) { + XCTAssertNil(error); + }]; } - - (void) testSaveAndGetEvent { __block XCTestExpectation *expectation = [self expectationWithDescription:@"Test finished running."]; @@ -536,83 +707,6 @@ - (void) testForMultipleBatches { }]; } -- (void) testEventsWithNoSessionId { - __block XCTestExpectation *expectation = [self expectationWithDescription:@"Test finished running."]; - //Removing Session Id from user defaults - [[NSUserDefaults standardUserDefaults] removeObjectForKey:AWSPinpointSessionKey]; - [[NSUserDefaults standardUserDefaults] synchronize]; - - - AWSPinpointEvent *event1 = [[AWSPinpointEvent alloc] initWithEventType:@"TEST" - eventTimestamp:123 - session:[[AWSPinpointSession alloc] initWithSessionId:nil withStartTime:[NSDate date] withStopTime:[NSDate date]] - attributes:nil - metrics:nil]; - // Test for default session id - [[[self.pinpoint.analyticsClient.eventRecorder saveEvent:event1] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { - AWSPinpointEvent *taskEvent = task.result; - XCTAssertNotNil(taskEvent.session.sessionId); - XCTAssertTrue([DEFAULT_SESSION_ID isEqualToString:taskEvent.session.sessionId]); - XCTAssertNil(task.error); - return nil; - }] waitUntilFinished]; - __block AWSPinpointEvent *startEvent; - __block AWSPinpointEvent *stopEvent; - [[[self.pinpoint.sessionClient startSession] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { - startEvent = task.result; - XCTAssertTrue([startEvent.eventType isEqualToString:@"_session.start"]); - XCTAssertTrue(startEvent.eventTimestamp > 0); - XCTAssertNotNil(startEvent.allAttributes); - XCTAssertEqual([startEvent.allAttributes count], 0); - XCTAssertNotNil(startEvent.session); - XCTAssertNotNil(startEvent.session.sessionId); - XCTAssertNotNil(startEvent.session.startTime); - XCTAssertNotNil(startEvent.allMetrics); - XCTAssertEqual([startEvent.allMetrics count], 0); - return nil; - }] waitUntilFinished]; - - [[[self.pinpoint.sessionClient stopSession] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { - stopEvent = task.result; - XCTAssertTrue([stopEvent.eventType isEqualToString:@"_session.stop"]); - XCTAssertTrue(stopEvent.eventTimestamp > 0); - XCTAssertNotNil(stopEvent.allAttributes); - XCTAssertEqual([stopEvent.allAttributes count], 0); - XCTAssertNotNil(stopEvent.session); - XCTAssertNotNil(stopEvent.session.sessionId); - XCTAssertNotNil(stopEvent.session.startTime); - XCTAssertNotNil(stopEvent.session.stopTime); - XCTAssertNotNil(stopEvent.allMetrics); - XCTAssertEqual([stopEvent.allMetrics count], 0); - return nil; - }] waitUntilFinished]; - //Tests that session info is not deleted from userdefaults - XCTAssertNotNil([[NSUserDefaults standardUserDefaults] dataForKey:AWSPinpointSessionKey]); - NSData *sessionData = [[NSUserDefaults standardUserDefaults] dataForKey:AWSPinpointSessionKey]; - AWSPinpointSession *previousSession = [NSKeyedUnarchiver unarchiveObjectWithData:sessionData]; - NSString *sessionId = previousSession.sessionId; - - AWSPinpointEvent *event2 = [[AWSPinpointEvent alloc] initWithEventType:@"TEST" - eventTimestamp:123 - session:[[AWSPinpointSession alloc] initWithSessionId:nil withStartTime:[NSDate date] withStopTime:[NSDate date]] - attributes:nil - metrics:nil]; - // Check if the session id matches the one in the user defaults. - [[self.pinpoint.analyticsClient.eventRecorder saveEvent:event2] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { - AWSPinpointEvent *taskEvent = task.result; - XCTAssertNotNil(taskEvent.session.sessionId); - XCTAssertTrue([sessionId isEqualToString:taskEvent.session.sessionId]); - XCTAssertNil(task.error); - [expectation fulfill]; - return nil; - }]; - - [self waitForExpectationsWithTimeout:5 handler:^(NSError * _Nullable error) { - XCTAssertNil(error); - }]; -} - - - (void) testRecordDirtyEventWithTooManyAttributes { __block XCTestExpectation *expectation = [self expectationWithDescription:@"Test finished running."]; diff --git a/AWSPinpointTests/AWSPinpointSessionClientTests.m b/AWSPinpointTests/AWSPinpointSessionClientTests.m index 267e350f00b..41af6be1fb3 100644 --- a/AWSPinpointTests/AWSPinpointSessionClientTests.m +++ b/AWSPinpointTests/AWSPinpointSessionClientTests.m @@ -18,6 +18,7 @@ #import "AWSPinpoint.h" #import #import "AWSTask.h" +#import "AWSPinpointContext.h" @class AWSPinpointSession; @@ -32,13 +33,20 @@ -(void) saveSession; @end @interface AWSPinpointSessionClientTests : XCTestCase +@property (nonatomic, strong) NSUserDefaults *userDefaults; +@end + +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; @end @implementation AWSPinpointSessionClientTests - (void)setUp { [super setUp]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointSessionClientTests"]; + self.userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"AWSPinpointSessionClientTests"]; [AWSTestUtility setupCognitoCredentialsProvider]; } @@ -47,16 +55,17 @@ - (void)tearDown { } - (void) clearSession { - [[NSUserDefaults standardUserDefaults] setObject:nil forKey:AWSPinpointSessionKey]; - [[NSUserDefaults standardUserDefaults] removeObjectForKey:AWSPinpointSessionKey]; - [[NSUserDefaults standardUserDefaults] synchronize]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointSessionClientTests"]; + [self.userDefaults setObject:nil forKey:AWSPinpointSessionKey]; + [self.userDefaults removeObjectForKey:AWSPinpointSessionKey]; + [self.userDefaults synchronize]; - NSData *data = [[NSUserDefaults standardUserDefaults] dataForKey:AWSPinpointSessionKey]; + NSData *data = [self.userDefaults dataForKey:AWSPinpointSessionKey]; AWSPinpointSession *session = [NSKeyedUnarchiver unarchiveObjectWithData:data]; NSLog(@"Session Object Should be Empty: %@",session.description); - XCTAssertNil([[NSUserDefaults standardUserDefaults] dataForKey:AWSPinpointSessionKey]); + XCTAssertNil([self.userDefaults dataForKey:AWSPinpointSessionKey]); } - (void)testConstructors { @@ -83,9 +92,17 @@ - (void)testSessionStart { maxStorageSize:5*1024*1024 sessionTimeout:5000]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; + [[pinpoint.analyticsClient.eventRecorder getEvents] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { + XCTAssertNotNil(task.result); + XCTAssertEqual([task.result count], 0); + return nil; + }]; + __block AWSPinpointEvent *event; [[[pinpoint.sessionClient startSession] continueWithBlock:^id _Nullable(AWSTask * _Nonnull task) { event = task.result; @@ -131,6 +148,8 @@ - (void)testSessionPause { maxStorageSize:5*1024*1024 sessionTimeout:5000]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; @@ -204,6 +223,8 @@ - (void)testSessionResume { maxStorageSize:5*1024*1024 sessionTimeout:5000]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; @@ -300,6 +321,8 @@ - (void)testSessionStop { maxStorageSize:5*1024*1024 sessionTimeout:5000]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; @@ -417,6 +440,8 @@ - (void)testSessionTimeout { maxStorageSize:5*1024*1024 sessionTimeout:5000]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; @@ -482,6 +507,8 @@ - (void)testSessionTimeoutNoCompletion { maxStorageSize:5*1024*1024 sessionTimeout:5000]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; @@ -546,6 +573,8 @@ - (void)testSessionImmediateTimeout { maxStorageSize:5*1024*1024 sessionTimeout:0]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; @@ -610,6 +639,8 @@ - (void)testSessionImmediateTimeoutNoCompletion { maxStorageSize:5*1024*1024 sessionTimeout:0]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; @@ -675,6 +706,8 @@ - (void) testSavingSessionFromMultipleThreads { maxStorageSize:5*1024*1024 sessionTimeout:0]; config.enableAutoSessionRecording = NO; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; [self cleanupForPinpoint:pinpoint]; diff --git a/AWSPinpointTests/AWSPinpointTargetingClientTests.m b/AWSPinpointTests/AWSPinpointTargetingClientTests.m index e8df01476a9..f5ba2fddcc9 100644 --- a/AWSPinpointTests/AWSPinpointTargetingClientTests.m +++ b/AWSPinpointTests/AWSPinpointTargetingClientTests.m @@ -17,6 +17,7 @@ #import "AWSTestUtility.h" #import "AWSPinpoint.h" #import "OCMock.h" +#import "AWSPinpointContext.h" NSString *const AWSPinpointTargetingClientErrorDomain = @"com.amazonaws.AWSPinpointAnalyticsClientErrorDomain"; @@ -24,18 +25,29 @@ @interface AWSPinpointTargetingClientTests : XCTestCase @property (nonatomic, strong) AWSPinpoint *pinpoint; @property (nonatomic, strong) AWSPinpointConfiguration *configuration; @property (nonatomic, strong) UIApplication *application; +@property (nonatomic, strong) NSUserDefaults *userDefaults; @end + +@interface AWSPinpointConfiguration() +@property (nonnull, strong) NSUserDefaults *userDefaults; +@end + @implementation AWSPinpointTargetingClientTests - (void)setUp { [super setUp]; [AWSTestUtility setupCognitoCredentialsProvider]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointTargetingClientTests"]; + self.userDefaults = [[NSUserDefaults alloc] initWithSuiteName:@"AWSPinpointTargetingClientTests"]; [self initializeMockApplicationWithOptOut:YES]; [self initializePinpointWithConfiguration:[self getDefaultAWSPinpointConfiguration] forceCreate:NO]; + [self.userDefaults removeObjectForKey:@"AWSPinpointEndpointAttributesKey"]; + [self.userDefaults removeObjectForKey:@"AWSPinpointEndpointMetricsKey"]; + [self.userDefaults synchronize]; } - (AWSPinpointConfiguration *)getDefaultAWSPinpointConfiguration { @@ -73,6 +85,9 @@ - (void)initializePinpointWithConfiguration:(AWSPinpointConfiguration *)configur if (forceCreate == YES) { self.configuration.appId = [[NSUUID UUID] UUIDString]; } + + configuration.userDefaults = self.userDefaults; + self.pinpoint = [AWSPinpoint pinpointWithConfiguration:configuration]; } @@ -118,7 +133,6 @@ - (void)testCurrentProfileWithSystemOptOutAndApplicationOptOut { [self setApplicationLevelOptOut:YES]; AWSPinpointEndpointProfile *profile = [self.pinpoint.targetingClient currentEndpointProfile]; - XCTAssertTrue([profile.optOut isEqualToString:@"ALL"]); } @@ -184,10 +198,15 @@ - (void)testCurrentProfileWithSystemOptInAndApplicationOptOutUnset { } - (void)testCurrentProfile { - AWSPinpointEndpointProfile *profile = [self.pinpoint.targetingClient currentEndpointProfile]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointTargetingClientTests"]; + AWSPinpointConfiguration *config = [[AWSPinpointConfiguration alloc] initWithAppId:@"testCurrentProfile" launchOptions:nil]; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; + + AWSPinpointEndpointProfile *profile = [pinpoint.targetingClient currentEndpointProfile]; XCTAssertNotNil(profile); XCTAssertNotNil(profile.endpointId); - XCTAssertTrue([profile.applicationId isEqualToString:self.configuration.appId]); + XCTAssertTrue([profile.applicationId isEqualToString:@"testCurrentProfile"]); XCTAssertTrue([profile.channelType isEqualToString:@"APNS"]); XCTAssertTrue([profile.optOut isEqualToString:@"ALL"]); XCTAssertNil(profile.address); @@ -228,13 +247,18 @@ - (void)testUpdateEndpointProfile { } - (void) testGlobalAttribute { - [self.pinpoint.targetingClient addAttribute:@[@"GlobalAttr1"] forKey:@"GlobalAttr1"]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointTargetingClientTests"]; + AWSPinpointConfiguration *config = [[AWSPinpointConfiguration alloc] initWithAppId:@"testGlobalAttribute" launchOptions:nil]; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; - AWSPinpointEndpointProfile *profile = [self.pinpoint.targetingClient currentEndpointProfile]; + [pinpoint.targetingClient addAttribute:@[@"GlobalAttr1"] forKey:@"GlobalAttr1"]; + + AWSPinpointEndpointProfile *profile = [pinpoint.targetingClient currentEndpointProfile]; XCTAssertNotNil(profile); XCTAssertNotNil(profile.endpointId); - XCTAssertTrue([profile.applicationId isEqualToString:self.configuration.appId]); + XCTAssertTrue([profile.applicationId isEqualToString:@"testGlobalAttribute"]); XCTAssertTrue([profile.channelType isEqualToString:@"APNS"]); XCTAssertTrue([profile.optOut isEqualToString:@"ALL"]); XCTAssertNil(profile.address); @@ -261,12 +285,11 @@ - (void) testGlobalAttribute { XCTAssertTrue([profile.demographic.model isEqualToString:[currentDevice model]]); XCTAssertTrue([profile.demographic.timezone isEqualToString:[[NSTimeZone systemTimeZone] name]]); XCTAssertTrue([profile.demographic.locale isEqualToString:autoUpdatingLocaleIdentifier]); - //XCTAssertTrue([profile.demographic.appVersion isEqualToString:@"1.0"]); XCTAssertTrue([profile.demographic.platform isEqualToString:[currentDevice systemName]]); XCTAssertTrue([profile.demographic.platformVersion isEqualToString:[currentDevice systemVersion]]); - [self.pinpoint.targetingClient removeAttributeForKey:@"GlobalAttr1"]; - profile = [self.pinpoint.targetingClient currentEndpointProfile]; + [pinpoint.targetingClient removeAttributeForKey:@"GlobalAttr1"]; + profile = [pinpoint.targetingClient currentEndpointProfile]; XCTAssertEqual([profile.allAttributes count], 0); XCTAssertEqual([profile.allMetrics count], 0); } @@ -323,13 +346,18 @@ - (void) testGlobalAttributeValidation { - (void) testGlobalMetric { - [self.pinpoint.targetingClient addMetric:@(123) forKey:@"GlobalMetr1"]; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointTargetingClientTests"]; + AWSPinpointConfiguration *config = [[AWSPinpointConfiguration alloc] initWithAppId:@"testGlobalMetric" launchOptions:nil]; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; - AWSPinpointEndpointProfile *profile = [self.pinpoint.targetingClient currentEndpointProfile]; + [pinpoint.targetingClient addMetric:@(123) forKey:@"GlobalMetr1"]; + + AWSPinpointEndpointProfile *profile = [pinpoint.targetingClient currentEndpointProfile]; XCTAssertNotNil(profile); XCTAssertNotNil(profile.endpointId); - XCTAssertTrue([profile.applicationId isEqualToString:self.configuration.appId]); + XCTAssertTrue([profile.applicationId isEqualToString:@"testGlobalMetric"]); XCTAssertTrue([profile.channelType isEqualToString:@"APNS"]); XCTAssertTrue([profile.optOut isEqualToString:@"ALL"]); XCTAssertNil(profile.address); @@ -360,8 +388,8 @@ - (void) testGlobalMetric { XCTAssertTrue([profile.demographic.platform isEqualToString:[currentDevice systemName]]); XCTAssertTrue([profile.demographic.platformVersion isEqualToString:[currentDevice systemVersion]]); - [self.pinpoint.targetingClient removeMetricForKey:@"GlobalMetr1"]; - profile = [self.pinpoint.targetingClient currentEndpointProfile]; + [pinpoint.targetingClient removeMetricForKey:@"GlobalMetr1"]; + profile = [pinpoint.targetingClient currentEndpointProfile]; XCTAssertEqual([profile.allAttributes count], 0); XCTAssertEqual([profile.allMetrics count], 0); } @@ -417,14 +445,20 @@ - (void) testGlobalMetricValidation { } - (void) testGlobalAttributeAndMetric { - [self.pinpoint.targetingClient addAttribute:@[@"GlobalAttr1"] forKey:@"GlobalAttr1"]; - [self.pinpoint.targetingClient addMetric:@(123) forKey:@"GlobalMetr1"]; + NSString *appId = @"testGlobalAttributeAndMetric"; + [[NSUserDefaults standardUserDefaults] removeSuiteNamed:@"AWSPinpointTargetingClientTests"]; + AWSPinpointConfiguration *config = [[AWSPinpointConfiguration alloc] initWithAppId:appId launchOptions:nil]; + config.userDefaults = self.userDefaults; + AWSPinpoint *pinpoint = [AWSPinpoint pinpointWithConfiguration:config]; - AWSPinpointEndpointProfile *profile = [self.pinpoint.targetingClient currentEndpointProfile]; + [pinpoint.targetingClient addAttribute:@[@"GlobalAttr1"] forKey:@"GlobalAttr1"]; + [pinpoint.targetingClient addMetric:@(123) forKey:@"GlobalMetr1"]; + + AWSPinpointEndpointProfile *profile = [pinpoint.targetingClient currentEndpointProfile]; XCTAssertNotNil(profile); XCTAssertNotNil(profile.endpointId); - XCTAssertTrue([profile.applicationId isEqualToString:self.configuration.appId]); + XCTAssertTrue([profile.applicationId isEqualToString:appId]); XCTAssertTrue([profile.channelType isEqualToString:@"APNS"]); XCTAssertTrue([profile.optOut isEqualToString:@"ALL"]); XCTAssertNil(profile.address); @@ -456,9 +490,9 @@ - (void) testGlobalAttributeAndMetric { XCTAssertTrue([profile.demographic.platform isEqualToString:[currentDevice systemName]]); XCTAssertTrue([profile.demographic.platformVersion isEqualToString:[currentDevice systemVersion]]); - [self.pinpoint.targetingClient removeAttributeForKey:@"GlobalAttr1"]; - [self.pinpoint.targetingClient removeMetricForKey:@"GlobalMetr1"]; - profile = [self.pinpoint.targetingClient currentEndpointProfile]; + [pinpoint.targetingClient removeAttributeForKey:@"GlobalAttr1"]; + [pinpoint.targetingClient removeMetricForKey:@"GlobalMetr1"]; + profile = [pinpoint.targetingClient currentEndpointProfile]; XCTAssertEqual([profile.allAttributes count], 0); XCTAssertEqual([profile.allMetrics count], 0); } diff --git a/AWSPolly.podspec b/AWSPolly.podspec index 6c845244f00..e68fd5486d0 100644 --- a/AWSPolly.podspec +++ b/AWSPolly.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSPolly' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSPolly/*.{h,m}' end diff --git a/AWSPolly/AWSPollyService.m b/AWSPolly/AWSPollyService.m index 933696af475..d76dd5cc145 100644 --- a/AWSPolly/AWSPollyService.m +++ b/AWSPolly/AWSPollyService.m @@ -26,7 +26,7 @@ #import "AWSPollyResources.h" static NSString *const AWSInfoPolly = @"Polly"; -static NSString *const AWSPollySDKVersion = @"2.6.2"; +static NSString *const AWSPollySDKVersion = @"2.6.3"; @interface AWSPollyResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSPolly/AWSPollySynthesizeSpeechURLBuilder.m b/AWSPolly/AWSPollySynthesizeSpeechURLBuilder.m index d2d1bb574be..ae76e9ede5b 100644 --- a/AWSPolly/AWSPollySynthesizeSpeechURLBuilder.m +++ b/AWSPolly/AWSPollySynthesizeSpeechURLBuilder.m @@ -16,7 +16,7 @@ #import "AWSPollySynthesizeSpeechURLBuilder.h" static NSString *const AWSInfoPollySynthesizeSpeechURLBuilder = @"PollySynthesizeSpeechUrlBuilder"; -static NSString *const AWSPollySDKVersion = @"2.6.2"; +static NSString *const AWSPollySDKVersion = @"2.6.3"; NSString *const AWSPollySynthesizeSpeechURLBuilderErrorDomain = @"com.amazonaws.AWSPollySynthesizeSpeechURLBuilderErrorDomain"; NSString *const AWSPollyPresignedUrlPath = @"v1/speech"; diff --git a/AWSPolly/Info.plist b/AWSPolly/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSPolly/Info.plist +++ b/AWSPolly/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSRekognition.podspec b/AWSRekognition.podspec index 5c28800f306..c000cd9329c 100644 --- a/AWSRekognition.podspec +++ b/AWSRekognition.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSRekognition' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSRekognition/*.{h,m}' end diff --git a/AWSRekognition/AWSRekognitionService.m b/AWSRekognition/AWSRekognitionService.m index c2bb2f3e111..828dd2741cb 100644 --- a/AWSRekognition/AWSRekognitionService.m +++ b/AWSRekognition/AWSRekognitionService.m @@ -26,7 +26,7 @@ #import "AWSRekognitionResources.h" static NSString *const AWSInfoRekognition = @"Rekognition"; -static NSString *const AWSRekognitionSDKVersion = @"2.6.2"; +static NSString *const AWSRekognitionSDKVersion = @"2.6.3"; @interface AWSRekognitionResponseSerializer : AWSJSONResponseSerializer diff --git a/AWSRekognition/Info.plist b/AWSRekognition/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSRekognition/Info.plist +++ b/AWSRekognition/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSS3.podspec b/AWSS3.podspec index 96f342b6720..b6c0bc683c4 100644 --- a/AWSS3.podspec +++ b/AWSS3.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSS3' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSS3/*.{h,m}' end diff --git a/AWSS3/AWSS3PreSignedURL.m b/AWSS3/AWSS3PreSignedURL.m index dc5dec51246..ec9504ba03f 100644 --- a/AWSS3/AWSS3PreSignedURL.m +++ b/AWSS3/AWSS3PreSignedURL.m @@ -26,7 +26,7 @@ static NSString *const AWSS3PreSignedURLBuilderAcceleratedEndpoint = @"s3-accelerate.amazonaws.com"; static NSString *const AWSInfoS3PreSignedURLBuilder = @"S3PreSignedURLBuilder"; -static NSString *const AWSS3PreSignedURLBuilderSDKVersion = @"2.6.2"; +static NSString *const AWSS3PreSignedURLBuilderSDKVersion = @"2.6.3"; @interface AWSS3PreSignedURLBuilder() diff --git a/AWSS3/AWSS3Service.m b/AWSS3/AWSS3Service.m index c810bec2c19..1506dcbdb61 100644 --- a/AWSS3/AWSS3Service.m +++ b/AWSS3/AWSS3Service.m @@ -28,7 +28,7 @@ #import "AWSS3Serializer.h" static NSString *const AWSInfoS3 = @"S3"; -static NSString *const AWSS3SDKVersion = @"2.6.2"; +static NSString *const AWSS3SDKVersion = @"2.6.3"; diff --git a/AWSS3/Info.plist b/AWSS3/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSS3/Info.plist +++ b/AWSS3/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSSES.podspec b/AWSSES.podspec index b4aa8a41c47..6028c4f17cd 100644 --- a/AWSSES.podspec +++ b/AWSSES.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSSES' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSSES/*.{h,m}' end diff --git a/AWSSES/AWSSESService.m b/AWSSES/AWSSESService.m index 873683cd04b..18f636c1e5b 100644 --- a/AWSSES/AWSSESService.m +++ b/AWSSES/AWSSESService.m @@ -26,7 +26,7 @@ #import "AWSSESResources.h" static NSString *const AWSInfoSES = @"SES"; -static NSString *const AWSSESSDKVersion = @"2.6.2"; +static NSString *const AWSSESSDKVersion = @"2.6.3"; @interface AWSSESResponseSerializer : AWSXMLResponseSerializer diff --git a/AWSSES/Info.plist b/AWSSES/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSSES/Info.plist +++ b/AWSSES/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSSNS.podspec b/AWSSNS.podspec index e47fcd0ea31..118b92dabca 100644 --- a/AWSSNS.podspec +++ b/AWSSNS.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSSNS' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSSNS/*.{h,m}' end diff --git a/AWSSNS/AWSSNSService.m b/AWSSNS/AWSSNSService.m index ed2333300da..34659e15fcf 100644 --- a/AWSSNS/AWSSNSService.m +++ b/AWSSNS/AWSSNSService.m @@ -26,7 +26,7 @@ #import "AWSSNSResources.h" static NSString *const AWSInfoSNS = @"SNS"; -static NSString *const AWSSNSSDKVersion = @"2.6.2"; +static NSString *const AWSSNSSDKVersion = @"2.6.3"; @interface AWSSNSResponseSerializer : AWSXMLResponseSerializer diff --git a/AWSSNS/Info.plist b/AWSSNS/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSSNS/Info.plist +++ b/AWSSNS/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSSQS.podspec b/AWSSQS.podspec index 3848c0f4ed2..383888d697d 100644 --- a/AWSSQS.podspec +++ b/AWSSQS.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSSQS' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSSQS/*.{h,m}' end diff --git a/AWSSQS/AWSSQSService.m b/AWSSQS/AWSSQSService.m index 479780d1ad0..907d60224fd 100644 --- a/AWSSQS/AWSSQSService.m +++ b/AWSSQS/AWSSQSService.m @@ -26,7 +26,7 @@ #import "AWSSQSResources.h" static NSString *const AWSInfoSQS = @"SQS"; -static NSString *const AWSSQSSDKVersion = @"2.6.2"; +static NSString *const AWSSQSSDKVersion = @"2.6.3"; @interface AWSSQSResponseSerializer : AWSXMLResponseSerializer diff --git a/AWSSQS/Info.plist b/AWSSQS/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSSQS/Info.plist +++ b/AWSSQS/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSSimpleDB.podspec b/AWSSimpleDB.podspec index 8882fb1f106..a4ed9843a21 100644 --- a/AWSSimpleDB.podspec +++ b/AWSSimpleDB.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSSimpleDB' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,6 +12,6 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCore', '2.6.2' + s.dependency 'AWSCore', '2.6.3' s.source_files = 'AWSSimpleDB/*.{h,m}' end diff --git a/AWSSimpleDB/AWSSimpleDBService.m b/AWSSimpleDB/AWSSimpleDBService.m index 7e80ea46827..4fcac926684 100644 --- a/AWSSimpleDB/AWSSimpleDBService.m +++ b/AWSSimpleDB/AWSSimpleDBService.m @@ -26,7 +26,7 @@ #import "AWSSimpleDBResources.h" static NSString *const AWSInfoSimpleDB = @"SimpleDB"; -static NSString *const AWSSimpleDBSDKVersion = @"2.6.2"; +static NSString *const AWSSimpleDBSDKVersion = @"2.6.3"; @interface AWSSimpleDBResponseSerializer : AWSXMLResponseSerializer diff --git a/AWSSimpleDB/Info.plist b/AWSSimpleDB/Info.plist index 713c5f9d4e1..83c54067c2d 100644 --- a/AWSSimpleDB/Info.plist +++ b/AWSSimpleDB/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 2.6.2 + 2.6.3 CFBundleSignature ???? CFBundleVersion diff --git a/AWSUserPoolsSignIn.podspec b/AWSUserPoolsSignIn.podspec index 13514baab6f..fa68afb5185 100644 --- a/AWSUserPoolsSignIn.podspec +++ b/AWSUserPoolsSignIn.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'AWSUserPoolsSignIn' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -12,8 +12,8 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/aws/aws-sdk-ios.git', :tag => s.version} s.requires_arc = true - s.dependency 'AWSCognitoIdentityProvider', '2.6.2' - s.dependency 'AWSAuthCore', '2.6.2' + s.dependency 'AWSCognitoIdentityProvider', '2.6.3' + s.dependency 'AWSAuthCore', '2.6.3' s.source_files = 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/**/*.{h,m}' s.public_header_files = 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/*.{h}' s.private_header_files = 'AWSAuthSDK/Sources/AWSUserPoolsSignIn/UserPoolsUI/*.{h}' diff --git a/AWSiOSSDKv2.podspec b/AWSiOSSDKv2.podspec index ac3685c9424..aa303789ba7 100644 --- a/AWSiOSSDKv2.podspec +++ b/AWSiOSSDKv2.podspec @@ -1,7 +1,7 @@ Pod::Spec.new do |s| s.name = 'AWSiOSSDKv2' - s.version = '2.6.2' + s.version = '2.6.3' s.summary = 'Amazon Web Services SDK for iOS.' s.description = 'The AWS SDK for iOS provides a library, code samples, and documentation for developers to build connected mobile applications using AWS.' @@ -15,103 +15,103 @@ Pod::Spec.new do |s| s.requires_arc = true s.subspec 'AWSCore' do |aws| - aws.dependency 'AWSCore', '2.6.2' + aws.dependency 'AWSCore', '2.6.3' end s.subspec 'AWSAPIGateway' do |apigateway| - apigateway.dependency 'AWSAPIGateway', '2.6.2' + apigateway.dependency 'AWSAPIGateway', '2.6.3' end s.subspec 'AutoScaling' do |autoscaling| - autoscaling.dependency 'AWSAutoScaling', '2.6.2' + autoscaling.dependency 'AWSAutoScaling', '2.6.3' end s.subspec 'CloudWatch' do |cloudwatch| - cloudwatch.dependency 'AWSCloudWatch', '2.6.2' + cloudwatch.dependency 'AWSCloudWatch', '2.6.3' end s.subspec 'Pinpoint' do |pp| - pp.dependency 'AWSPinpoint', '2.6.2' + pp.dependency 'AWSPinpoint', '2.6.3' end s.subspec 'AWSCognito' do |cognito| - cognito.dependency 'AWSCognito', '2.6.2' + cognito.dependency 'AWSCognito', '2.6.3' end s.subspec 'AWSCognitoIdentityProvider' do |cognitoidentityprovider| - cognitoidentityprovider.dependency 'AWSCognitoIdentityProvider', '2.6.2' + cognitoidentityprovider.dependency 'AWSCognitoIdentityProvider', '2.6.3' end s.subspec 'DynamoDB' do |ddb| - ddb.dependency 'AWSDynamoDB', '2.6.2' + ddb.dependency 'AWSDynamoDB', '2.6.3' end s.subspec 'EC2' do |ec2| - ec2.dependency 'AWSEC2', '2.6.2' + ec2.dependency 'AWSEC2', '2.6.3' end s.subspec 'ElasticLoadBalancing' do |elasticloadbalancing| - elasticloadbalancing.dependency 'AWSElasticLoadBalancing', '2.6.2' + elasticloadbalancing.dependency 'AWSElasticLoadBalancing', '2.6.3' end s.subspec 'AWSIoT' do |iot| - iot.dependency 'AWSIoT', '2.6.2' + iot.dependency 'AWSIoT', '2.6.3' end s.subspec 'Kinesis' do |kinesis| - kinesis.dependency 'AWSKinesis', '2.6.2' + kinesis.dependency 'AWSKinesis', '2.6.3' end s.subspec 'AWSKMS' do |kms| - kms.dependency 'AWSKMS', '2.6.2' + kms.dependency 'AWSKMS', '2.6.3' end s.subspec 'AWSLambda' do |lambda| - lambda.dependency 'AWSLambda', '2.6.2' + lambda.dependency 'AWSLambda', '2.6.3' end s.subspec 'AWSLex' do |lex| - lex.dependency 'AWSLex', '2.6.2' + lex.dependency 'AWSLex', '2.6.3' end s.subspec 'AWSLogs' do |log| - log.dependency 'AWSLogs', '2.6.2' + log.dependency 'AWSLogs', '2.6.3' end s.subspec 'AWSMachineLearning' do |machinelearning| - machinelearning.dependency 'AWSMachineLearning', '2.6.2' + machinelearning.dependency 'AWSMachineLearning', '2.6.3' end s.subspec 'AWSPolly' do |polly| - polly.dependency 'AWSPolly', '2.6.2' + polly.dependency 'AWSPolly', '2.6.3' end s.subspec 'MobileAnalytics' do |mobileanalytics| - mobileanalytics.dependency 'AWSMobileAnalytics', '2.6.2' + mobileanalytics.dependency 'AWSMobileAnalytics', '2.6.3' end s.subspec 'AWSRekognition' do |rekognition| - rekognition.dependency 'AWSRekognition', '2.6.2' + rekognition.dependency 'AWSRekognition', '2.6.3' end s.subspec 'AWSS3' do |s3| - s3.dependency 'AWSS3', '2.6.2' + s3.dependency 'AWSS3', '2.6.3' end s.subspec 'AWSSES' do |ses| - ses.dependency 'AWSSES', '2.6.2' + ses.dependency 'AWSSES', '2.6.3' end s.subspec 'AWSSimpleDB' do |simpledb| - simpledb.dependency 'AWSSimpleDB', '2.6.2' + simpledb.dependency 'AWSSimpleDB', '2.6.3' end s.subspec 'AWSSNS' do |sns| - sns.dependency 'AWSSNS', '2.6.2' + sns.dependency 'AWSSNS', '2.6.3' end s.subspec 'AWSSQS' do |sqs| - sqs.dependency 'AWSSQS', '2.6.2' + sqs.dependency 'AWSSQS', '2.6.3' end end diff --git a/CHANGELOG.md b/CHANGELOG.md index dfb42b51c64..ea085ebbc9d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,17 @@ # AWS Mobile SDK for iOS CHANGELOG + +## 2.6.3 + +### Bug fixes + +* **Amazon Pinpoint** + * Removed unused variable causing intermittent crashes. + * Fix deadlock bug in submission of events. + +* **Amazon Mobile Analytics** + * Fixed bug where an empty string causes app to crash when writing it to file. + ## 2.6.2 ### New features diff --git a/Scripts/GenerateAppleDocs.sh b/Scripts/GenerateAppleDocs.sh index 8e691993cd6..0f789010e4f 100644 --- a/Scripts/GenerateAppleDocs.sh +++ b/Scripts/GenerateAppleDocs.sh @@ -9,7 +9,7 @@ function cleanup } -VERSION="2.6.2" +VERSION="2.6.3" if [ -n $1 ] && [ "$1" == "clean" ]; then cleanup