Skip to content
This repository has been archived by the owner on Dec 4, 2024. It is now read-only.

prepare 1.0.0-beta23 release #18

Merged
merged 348 commits into from
Aug 30, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
348 commits
Select commit Hold shift + click to select a range
ffccf37
ensure that LdClient instances are always cleaned up in tests
eli-darkly Mar 25, 2019
ee940e3
Bump LD Common to beta4
torchhound Mar 26, 2019
420c6b2
Fixed dotnet restore errors, forgot to bump LD Common beta4 in tests
torchhound Mar 26, 2019
c8b23ae
Merge branch 'eb/ch34904/ci-tests' into jc/ch32871/rm-essentials
eli-darkly Mar 26, 2019
eae5ec6
Merge pull request #29 from launchdarkly/jc/ch32871/rm-essentials
eli-darkly Mar 26, 2019
27c66ed
Add "os" and "device" attributes to user
eli-darkly Mar 27, 2019
59191cd
create package during build + update dependency versions
eli-darkly Mar 27, 2019
b1274fa
fix dependency version
eli-darkly Mar 27, 2019
94a39af
fix unstable test state
eli-darkly Mar 28, 2019
3986efd
Merge pull request #30 from launchdarkly/eb/ch22803/os-device
eli-darkly Mar 29, 2019
911cdba
Merge pull request #31 from launchdarkly/eb/ch35143/packaging
eli-darkly Mar 29, 2019
771e9e8
Merge branch 'master' of github.com:launchdarkly/xamarin-client
eli-darkly Apr 5, 2019
a324295
apply markdown templates (#33)
bwoskow-ld May 3, 2019
8aeff1e
Merge branch 'master' of github.com:launchdarkly/xamarin-client-sdk
bwoskow-ld May 3, 2019
bcffc7e
use new package naming convention
eli-darkly May 14, 2019
fc6d39d
Merge pull request #34 from launchdarkly/eb/ch36754/package-names
eli-darkly May 15, 2019
2db496e
Merge branch 'master' of github.com:launchdarkly/xamarin-client
eli-darkly May 16, 2019
62ebda0
Merge branch 'master' of github.com:launchdarkly/xamarin-client
eli-darkly May 17, 2019
32437cb
clean up platform code, don't throw NotImplementedException
eli-darkly May 18, 2019
0c6d53b
Merge pull request #35 from launchdarkly/eb/ch20261/dotnet-standard-1
eli-darkly May 20, 2019
b3fdb73
.NET Standard 2.0 implementation of persistent storage
eli-darkly Jun 4, 2019
eb01cde
better error handling for persistent storage
eli-darkly Jun 4, 2019
87883f5
Merge pull request #36 from launchdarkly/eb/ch20261/dotnet-standard-2
eli-darkly Jun 4, 2019
2f8cdfb
fix try block
eli-darkly Jun 4, 2019
2a49acb
comment
eli-darkly Jun 4, 2019
c6f8d78
Merge pull request #37 from launchdarkly/eb/ch20261/dotnet-standard-3
eli-darkly Jun 4, 2019
37844f1
simplify backgrounding implementation, cleanup async usage
eli-darkly Jun 7, 2019
1e91ef2
misc fixes
eli-darkly Jun 7, 2019
3e0b5b8
basic components of Xamarin build on Mac
eli-darkly Jun 7, 2019
c701fd8
misc fixes
eli-darkly Jun 7, 2019
531633d
misc fixes
eli-darkly Jun 7, 2019
c763ea9
fix var name
eli-darkly Jun 7, 2019
71f9979
restore packages
eli-darkly Jun 7, 2019
4275867
install Android SDK components
eli-darkly Jun 10, 2019
0177b39
clarifying comment
eli-darkly Jun 10, 2019
75c4b8f
remove unnecessary checks for AggregateException
eli-darkly Jun 10, 2019
490889a
add config option for whether to persist flags
eli-darkly Jun 11, 2019
1102861
Merge pull request #38 from launchdarkly/eb/ch34893/no-platform-adapter
eli-darkly Jun 13, 2019
fe579e8
Merge branch 'master' into eb/ch40485/mobile-ci-build
eli-darkly Jun 13, 2019
7ef51d9
suppress spurious sdkmanager error
eli-darkly Jun 13, 2019
6c80e5a
split out Android job
eli-darkly Jun 18, 2019
6cc44a9
add missing script
eli-darkly Jun 18, 2019
75e5bfb
build only main project
eli-darkly Jun 18, 2019
69dce01
fix Android build
eli-darkly Jun 18, 2019
1f1f1c9
make script executable
eli-darkly Jun 18, 2019
9591da7
make script executable
eli-darkly Jun 18, 2019
2cfb378
try Android 27 image
eli-darkly Jun 18, 2019
1215254
fix script permission
eli-darkly Jun 19, 2019
9b8719e
cached data is a directory, not a file
eli-darkly Jun 19, 2019
75422e2
fix path in if test
eli-darkly Jun 19, 2019
f732f71
Merge pull request #40 from launchdarkly/eb/ch40485/mobile-ci-build
eli-darkly Jun 19, 2019
0d8e616
Merge pull request #39 from launchdarkly/eb/ch34893/config-storage
eli-darkly Jun 20, 2019
6c05c2e
tests of LdClient with actual HTTP, + misc test cleanup
eli-darkly Jun 23, 2019
eb781c3
fix malformed log message
eli-darkly Jun 23, 2019
fd93cfe
add tests for cached flags in offline mode
eli-darkly Jun 23, 2019
feed22d
tiny fix to avoid doing ToString twice
eli-darkly Jun 23, 2019
1a417f3
syntax error
eli-darkly Jun 24, 2019
bdcc5f1
comment
eli-darkly Jun 24, 2019
4b276c3
simplify test methods by parameterizing
eli-darkly Jun 24, 2019
1205e52
fix test cleanup concurrency problem
eli-darkly Jun 24, 2019
810179e
make standard test suite run in iOS test project
eli-darkly Jun 24, 2019
d55c90a
run iOS tests in CI
eli-darkly Jun 24, 2019
732f31f
syntax error
eli-darkly Jun 24, 2019
3bd1f8f
misc build fixes
eli-darkly Jun 24, 2019
39d124b
cleanup boilerplate code
eli-darkly Jun 24, 2019
428a912
Merge pull request #41 from launchdarkly/eb/ch40485/client-smoke-tests
eli-darkly Jun 25, 2019
e166d73
add a new iOS test project made from scratch
eli-darkly Jun 25, 2019
2022ad9
revert accidental rename
eli-darkly Jun 25, 2019
e223aa3
use mono-mdk
eli-darkly Jun 25, 2019
486ab22
rm obsolete project
eli-darkly Jun 26, 2019
291d9d3
better test output processing
eli-darkly Jun 26, 2019
0a387d8
fix script exit logic
eli-darkly Jun 26, 2019
edd7c67
Merge pull request #42 from launchdarkly/eb/ch40485/mobile-tests
eli-darkly Jun 26, 2019
0020505
add a new Android test project made from scratch
eli-darkly Jun 27, 2019
122cef1
try building the Android test project
eli-darkly Jun 27, 2019
fe45d95
better organization of commands into labeled groups
eli-darkly Jun 27, 2019
7a92825
make commands a little more readable
eli-darkly Jun 27, 2019
8db5b2a
build with xabuild
eli-darkly Jun 27, 2019
4f674ee
rm autogenerated UI file that for some reason broke the build
eli-darkly Jun 27, 2019
fe262f3
auto-restore
eli-darkly Jun 27, 2019
b41f585
misc cleanup
eli-darkly Jun 27, 2019
fdc1179
actually run the tests
eli-darkly Jun 27, 2019
0744bd2
install libpulse0
eli-darkly Jun 27, 2019
5c9b1c7
misc Android CI fixes
eli-darkly Jun 27, 2019
9d6eb2e
better test log output
eli-darkly Jun 27, 2019
3c4cbc4
better log capturing
eli-darkly Jun 28, 2019
72cfdcb
skip Android tests that use WireMock (for now) + misc test fixes
eli-darkly Jun 28, 2019
bbdf0f2
rm unused import
eli-darkly Jun 28, 2019
47011c1
use CircleCI helper script
eli-darkly Jul 1, 2019
1f28e35
comment
eli-darkly Jul 1, 2019
4440392
Merge pull request #43 from launchdarkly/eb/ch40485/android-tests
eli-darkly Jul 1, 2019
fdef9dd
Implement unique anon user key in .NET Standard
eli-darkly Jul 1, 2019
18339bd
syntax error
eli-darkly Jul 1, 2019
08e48dd
list tests in .NET Standard
eli-darkly Jul 1, 2019
ee2dd4d
suppress ASP.NET debug output in iOS
eli-darkly Jul 1, 2019
b0b9910
Revert "suppress ASP.NET debug output in iOS"
eli-darkly Jul 1, 2019
6b73190
fix test state cleanup
eli-darkly Jul 1, 2019
7025940
add lower-level unit test for device ID
eli-darkly Jul 1, 2019
675a2c1
Merge pull request #44 from launchdarkly/eb/ch42260/user-uuid
eli-darkly Jul 1, 2019
807428d
clean up structure of conditionally compiled code
eli-darkly Jul 2, 2019
06902cf
merge some iOS code
eli-darkly Jul 2, 2019
0a0d21f
fix some more broken references
eli-darkly Jul 2, 2019
eeca41e
improvements to CONTRIBUTING file
eli-darkly Jul 2, 2019
ddff9a1
capitalization
eli-darkly Jul 2, 2019
b2ef03b
Merge pull request #45 from launchdarkly/eb/ch42316/platform-code-reorg
eli-darkly Jul 2, 2019
ec0f5cd
1.0.0-beta18
eli-darkly Jul 2, 2019
a7798ea
Merge branch 'master' of github.com:launchdarkly/xamarin-client-sdk
eli-darkly Jul 3, 2019
7058f3c
add scripts for packaging & releasing
eli-darkly Jul 3, 2019
15e58b1
indents
eli-darkly Jul 3, 2019
fa5106b
comments
eli-darkly Jul 3, 2019
baedda9
Merge pull request #46 from launchdarkly/eb/ch35143/release-script
eli-darkly Jul 3, 2019
6553a7c
typo
eli-darkly Jul 9, 2019
56a6ff1
call flag change listeners asynchronously
eli-darkly Jul 9, 2019
4c7ee0f
copy Android implementation from Xamarin.Essentials
eli-darkly Jul 9, 2019
3a2a2e0
indents
eli-darkly Jul 9, 2019
184a054
indents
eli-darkly Jul 9, 2019
81aab83
doc comment
eli-darkly Jul 9, 2019
001b98c
simpler Android AsyncScheduler implementation
eli-darkly Jul 9, 2019
89897d8
typo
eli-darkly Jul 11, 2019
99cec42
add test for deferring listener calls
eli-darkly Jul 11, 2019
51ab920
Merge pull request #47 from launchdarkly/eb/ch42408/listener-deadlock
eli-darkly Jul 11, 2019
aa27944
allow singleton to be cleared on disposal; use better concurrency pra…
eli-darkly Jul 12, 2019
267a0e0
fix race condition in CreateInstance
eli-darkly Jul 12, 2019
f29164e
Merge pull request #48 from launchdarkly/eb/ch43173/dispose-singleton
eli-darkly Jul 12, 2019
4b014fe
add note about VS 2015 issue
eli-darkly Jul 15, 2019
e0dbf9d
Merge pull request #49 from launchdarkly/eb/ch38860/readme-vs
eli-darkly Jul 15, 2019
30a7359
rethink flag change event interface and implementation
eli-darkly Jul 17, 2019
157b9d0
doc comments
eli-darkly Jul 17, 2019
64eef47
try pinning to older versions of Mono packages
eli-darkly Jul 18, 2019
7e986ab
pin apt repo
eli-darkly Jul 18, 2019
5cbd2a2
Merge branch 'eb/build-debug' into eb/ch42887/listener-syntax
eli-darkly Jul 18, 2019
1a1180a
Merge pull request #51 from launchdarkly/eb/build-debug
eli-darkly Jul 18, 2019
177b597
Merge pull request #50 from launchdarkly/eb/ch42887/listener-syntax
eli-darkly Jul 18, 2019
2569142
bump common lib version, use User.Builder
eli-darkly Jul 24, 2019
8a6fe6a
Moved some functions for greater clarity, fixed isInitialized behavio…
torchhound Jul 24, 2019
9707089
Fixed NullReferenceException in ResetProcessorForForeground
torchhound Jul 24, 2019
0fedbd7
Merge pull request #53 from launchdarkly/jc/fix-null-background
torchhound Jul 25, 2019
8e02241
Added nameof(configuration), added Online check to StartUpdateProcessor
torchhound Jul 25, 2019
f5c4f3a
Merge branch 'master' into jc/42407/load-cached-flags
torchhound Jul 25, 2019
ecd0f47
Merge branch 'master' into jc/42407/load-cached-flags
torchhound Jul 25, 2019
4d36317
use prebuilt Xamarin Android image (#55)
eli-darkly Jul 25, 2019
306eaaa
Applied nameof to incorrect configuration
torchhound Jul 25, 2019
219ff81
Added back null check in Android Connectivity
torchhound Jul 25, 2019
55207d6
Reverted Initialized behavior, was a red herring during debugging
torchhound Jul 25, 2019
ce8cf9d
Added volatile to online per review comment
torchhound Jul 25, 2019
f0b2068
Merge branch 'master' into eb/ch43685/user-builder
eli-darkly Jul 26, 2019
79d4920
Merge pull request #52 from launchdarkly/eb/ch43685/user-builder
eli-darkly Jul 26, 2019
ce865ad
change tag of Xamarin Android Docker image
eli-darkly Jul 27, 2019
a82da03
Merge branch 'master' into jc/42407/load-cached-flags
torchhound Jul 29, 2019
8264b3c
Add api28 docker tag to circleci android test
torchhound Jul 29, 2019
52c15da
Add api27 docker tag to circleci android test
torchhound Jul 29, 2019
50e4c81
Added tests to trigger StartUpdateProcessor and StartUpdateProcessorA…
torchhound Jul 29, 2019
881cbdf
use immutable user API
eli-darkly Jul 29, 2019
080e12e
update dependency
eli-darkly Jul 29, 2019
d3f10fd
fix encoded user constants in tests
eli-darkly Jul 29, 2019
85f1c01
Changed misleading test names
torchhound Jul 29, 2019
b8e194f
Merge pull request #56 from launchdarkly/eb/ch44676/immutable-user
eli-darkly Jul 30, 2019
df1f0e9
add tests for user platform metadata
eli-darkly Jul 30, 2019
9ead721
typo
eli-darkly Jul 30, 2019
f7ddb29
make Configuration immutable, add builder
eli-darkly Jul 30, 2019
3614e66
revert accidental changes
eli-darkly Jul 30, 2019
c9c5a74
Change JToken to ImmutableJsonValue in public API
eli-darkly Jul 30, 2019
9c12530
Merge pull request #57 from launchdarkly/eb/detect-platform
eli-darkly Jul 30, 2019
9a02c6e
whitespace
eli-darkly Jul 30, 2019
9fc6d84
whitespace
eli-darkly Jul 30, 2019
aaa44de
Merge pull request #54 from launchdarkly/jc/42407/load-cached-flags
torchhound Jul 30, 2019
1942dca
Merge branch 'master' into eb/ch44212/immutable-json-value
eli-darkly Jul 30, 2019
e075148
Merge pull request #58 from launchdarkly/eb/ch44212/immutable-json-value
eli-darkly Jul 30, 2019
20110d6
Merge branch 'master' into eb/ch44212/config-builder
eli-darkly Jul 30, 2019
4e6e3fb
fix merge
eli-darkly Jul 30, 2019
e91bb1f
fix merge
eli-darkly Jul 30, 2019
a0ba32d
fix merge
eli-darkly Jul 30, 2019
f23bd49
typo
eli-darkly Jul 30, 2019
27357c5
Merge pull request #59 from launchdarkly/eb/ch44212/config-builder
eli-darkly Jul 30, 2019
eebea89
add project property that's required by recent Xamarin Android versions
eli-darkly Jul 31, 2019
ff0e29c
debug logging of exception stacktrace
eli-darkly Jul 31, 2019
caef323
add internal property for detecting current build platform
eli-darkly Jul 31, 2019
463df24
misc doc comment improvements
eli-darkly Jul 31, 2019
ee9b86d
make AllFlags return immutable values; add PlatformType
eli-darkly Jul 31, 2019
7e840c0
more debug logging
eli-darkly Jul 31, 2019
1b428af
change PlatformType to static, add tests
eli-darkly Jul 31, 2019
aabdc9e
the IDE keeps wanting to refresh this file so let's just commit the c…
eli-darkly Jul 31, 2019
303aa97
Merge pull request #61 from launchdarkly/eb/misc-fixes
eli-darkly Jul 31, 2019
5ec4e69
Merge branch 'master' of github.com:launchdarkly/xamarin-client-sdk
eli-darkly Jul 31, 2019
dd52e74
use immutable JSON values in FlagChangedEvent
eli-darkly Aug 1, 2019
850ce75
Remove redundant convenience methods
eli-darkly Aug 1, 2019
f986012
fix tests
eli-darkly Aug 1, 2019
21d459a
Merge pull request #62 from launchdarkly/eb/ch45167/event-args-json
eli-darkly Aug 1, 2019
590da34
remove deprecated stuff, update for CommonSdk 3.x API changes (#63)
eli-darkly Aug 5, 2019
8fa98c7
make more things sealed and/or internal
eli-darkly Aug 5, 2019
a20aa63
Merge pull request #64 from launchdarkly/eb/sealed-internal
eli-darkly Aug 6, 2019
827243b
Removed unused locks, simplified all flags to match Android behavior,…
torchhound Aug 6, 2019
82b14f2
Merge branch 'master' into jc/45269/initialized-behavior
torchhound Aug 6, 2019
3a7bb49
bump CommonSdk version
eli-darkly Aug 6, 2019
b7b4e9f
1.0.0-beta20
eli-darkly Aug 6, 2019
94a88b0
Added streaming mode check when entering background, added unit tests…
torchhound Aug 6, 2019
0268dd3
1.0.0-beta21
eli-darkly Aug 6, 2019
da45bd4
Removed redundant config online check in start update processor, remo…
torchhound Aug 6, 2019
dbba466
Simplified backgroundedWhileStreaming, made backgroundedWhileStreamin…
torchhound Aug 7, 2019
9055550
Remove unnecessary backgroundedWhileStreaming, always reset _disableS…
torchhound Aug 7, 2019
dc97900
Merge pull request #66 from launchdarkly/jc/44753/background-update-t…
torchhound Aug 7, 2019
70389ca
Changed Initialized behavior to new spec, added testing, changed comm…
torchhound Aug 9, 2019
9de62e4
Merge branch 'master' into jc/45269/initialized-behavior
torchhound Aug 9, 2019
02fa10c
Fix merge bug with constant that doesn't exist anymore
torchhound Aug 9, 2019
a0c6ae2
Simplified initialized assignment, removed unnecssary static keyword
torchhound Aug 9, 2019
6018077
Improved Initialized comment in ILdClient
torchhound Aug 9, 2019
4b8c8ef
don't use default .NET HTTP handler (#67)
eli-darkly Aug 12, 2019
e77d798
Merge branch 'master' into jc/45269/initialized-behavior
eli-darkly Aug 12, 2019
f6d44e2
fix test state contamination in cached flag tests
eli-darkly Aug 12, 2019
2c3e652
Addressing PR feedback about keeping warn logging for variation when …
torchhound Aug 12, 2019
b3524f6
Merge branch 'jc/45269/initialized-behavior' of https://github.com/la…
torchhound Aug 12, 2019
a4e1384
Merge pull request #68 from launchdarkly/eb/ch45269/fix-test-state
eli-darkly Aug 12, 2019
4de70df
Removed warn log from incorrect default return, added check for when …
torchhound Aug 12, 2019
d8f4207
Merge branch 'jc/45269/initialized-behavior' of https://github.com/la…
torchhound Aug 12, 2019
a355b97
Merge pull request #65 from launchdarkly/jc/45269/initialized-behavior
torchhound Aug 12, 2019
83261c4
Merge branch 'master' of github.com:launchdarkly/xamarin-client-sdk
eli-darkly Aug 13, 2019
8ce6599
Merge branch 'master' of github.com:launchdarkly/xamarin-client-sdk
eli-darkly Aug 20, 2019
b586979
send event for evaluation even if client isn't inited
eli-darkly Aug 21, 2019
2186374
make sure Identify/IdentifyAsync only completes when we have new flags
eli-darkly Aug 21, 2019
be799c6
Merge pull request #69 from launchdarkly/eb/ch46786/event-when-not-in…
eli-darkly Aug 21, 2019
82c087e
add helper scripts
eli-darkly Aug 21, 2019
b263266
Merge pull request #71 from launchdarkly/eb/build-script
eli-darkly Aug 21, 2019
ce24a81
Merge pull request #70 from launchdarkly/eb/ch46942/identify-await
eli-darkly Aug 21, 2019
972fc87
Changed Online to use WaitSafely instead of storing result in a var
torchhound Aug 21, 2019
84ea43b
Merge pull request #72 from launchdarkly/jc/ch46355/online-wait
torchhound Aug 21, 2019
e0acb8f
Added identical value check to SetOnlineAsync
torchhound Aug 21, 2019
b82dd4c
Move value check inside of lock for Android unit test
torchhound Aug 21, 2019
a17153e
Added second value check inside Online, moved value check into try in…
torchhound Aug 21, 2019
63b0543
Merge pull request #73 from launchdarkly/jc/ch46986/online-noop
torchhound Aug 21, 2019
d9d01dc
disable REPORT mode because it doesn't work in Android yet
eli-darkly Aug 23, 2019
3e258b6
Merge pull request #75 from launchdarkly/eb/ch47341-disable-report
eli-darkly Aug 26, 2019
50f963c
refactor connection state management, replace Online property with Of…
eli-darkly Aug 26, 2019
e2ce9b0
remove HttpClientTimeout in configuration, use ConnectionTimeout (#77)
eli-darkly Aug 27, 2019
be3e317
misc fixes to background mode logic, add tests for it (#78)
eli-darkly Aug 27, 2019
240a2ef
fix comments
eli-darkly Aug 28, 2019
d78754c
misc fixes for flaky tests
eli-darkly Aug 28, 2019
6866f85
update WireMock, re-enable HTTP tests for Android
eli-darkly Aug 29, 2019
e48a0b0
more stable way of synchronizing the background mode tests
eli-darkly Aug 29, 2019
84991fc
Merge pull request #79 from launchdarkly/eb/ch42944/android-http-tests
eli-darkly Aug 29, 2019
20d8ec8
put event processor off/online based on Offline property + network st…
eli-darkly Aug 30, 2019
23f2c85
don't post more events if we're offline
eli-darkly Aug 30, 2019
dc2d86f
don't send identify event if we're offline
eli-darkly Aug 30, 2019
eaf791f
Merge pull request #80 from launchdarkly/eb/ch47661/offline-flush
eli-darkly Aug 30, 2019
dfdc9aa
generate XML comment files
eli-darkly Aug 30, 2019
ad45b10
try skipping XML step in Android CI job because msbuild will fail
eli-darkly Aug 30, 2019
a3a816d
Merge pull request #81 from launchdarkly/eb/ch47796/xml-comments
eli-darkly Aug 30, 2019
dffedd4
rm unused type
eli-darkly Aug 30, 2019
44dbb6a
XML comment fixes
eli-darkly Aug 30, 2019
e4347b7
version 1.0.0-beta23
eli-darkly Aug 30, 2019
eb4830b
changelog additions
eli-darkly Aug 30, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ jobs:
docker:
- image: ldcircleci/ld-xamarin-android-linux:api27

environment:
LD_SKIP_XML_DOCS: 1 # there seems to be a bug in Xamarin Android builds on Linux that makes the XML build step fail

steps:
- checkout

Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
[Bb]in/
packages/
TestResults/
test-packages/

# globs
Makefile.in
Expand Down
23 changes: 23 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,29 @@
All notable changes to the LaunchDarkly Client-side SDK for Xamarin will be documented in this file.
This project adheres to [Semantic Versioning](http://semver.org).

## [1.0.0-beta23] - 2019-08-30
### Added:
- XML documentation comments are now included in the package, so they should be visible in Visual Studio for all LaunchDarkly types and methods.

### Changed:
- The `Online` property of `LdClient` was not useful because it could reflect either a deliberate change to whether the client is allowed to go online (that is, it would be false if you had set `Offline` to true in the configuration), _or_ a change in network availability. It has been removed and replaced with `Offline`, which is only used for explicitly forcing the client to be offline. This is a read-only property; to set it, use `SetOffline` or `SetOfflineAsync`.
- The synchronous `Identify` method now requires a timeout parameter, and returns false if it times out.
- `LdClient.Initialized` is now a property, not a method.
- `LdClient.Version` is now static, since it describes the entire package rather than a client instance.
- In `Configuration` and `IConfigurationBuilder`, `HttpClientTimeout` is now `ConnectionTimeout`.
- There is now more debug-level logging for stream connection state changes.

### Fixed:
- Network availability changes are now detected in both Android and iOS. The SDK should not attempt to connect to LaunchDarkly if the OS has told it that the network is unavailable.
- Background polling was never enabled, even if `Configuration.EnableBackgroundUpdating` was true.
- When changing from offline to online by setting `client.Online = true`, or calling `await client.SetOnlineAsync(true)` (the equivalent now would be `client.Offline = false`, etc.), the SDK was returning too soon before it had acquired flags from LaunchDarkly. The known issues in 1.0.0-beta22 have been fixed.
- If the SDK was online and then was explicitly set to be offline, or if network connectivity was lost, the SDK was still attempting to send analytics events. It will no longer do so.
- If the SDK was originally set to be offline and then was put online, the SDK was _not_ sending analytics events. Now it will.

### Removed:
- `ConfigurationBuilder.UseReport`. Due to [an issue](https://github.com/xamarin/xamarin-android/issues/3544) with the Android implementation of HTTP, the HTTP REPORT method is not currently usable in the Xamarin SDK.
- `IConnectionManager` interface. The SDK now always uses a platform-appropriate implementation of this logic.

## [1.0.0-beta22] - 2019-08-12
### Changed:
- By default, on Android and iOS the SDK now uses Xamarin's platform-specific implementations of `HttpMessageHandler` that are based on native APIs, rather than the basic `System.Net.Http.HttpClientHandler`. This improves performance and stability on mobile platforms.
Expand Down
10 changes: 10 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,3 +50,13 @@ You can run the mobile test projects from Visual Studio (the iOS tests require M
Note that the mobile unit tests currently do not cover background-mode behavior or connectivity detection.

### Packaging/releasing

Run `./scripts/update-version.sh <VERSION>` to set the project version.

Run `./scripts/release.sh` to build the project for all target frameworks and upload the package to NuGet. You must have already configured the necessary NuGet key locally.

To verify that the package can be built without uploading it, run `./scripts/package.sh`.

### Building a temporary package

If you need to build a `.nupkg` for testing another application (in cases where linking directly to this project is not an option), run `./scripts/build-test-package.sh`. This will create a package with a unique version string in `./test-packages`. You can then set your other project to use `test-packages` as a NuGet package source.
32 changes: 32 additions & 0 deletions scripts/build-test-package.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#!/bin/bash

set -e

# build-test-package.sh
# Temporarily changes the project version to a unique prerelease version string based on the current
# date and time, builds a .nupkg package, and places the package in ./test-packages. You can then use
# the test-packages directory as a package source to use this package in our testing tools.

TEST_VERSION="0.0.1-$(date +%Y%m%d.%H%M%S)"
PROJECT_FILE=src/LaunchDarkly.XamarinSdk/LaunchDarkly.XamarinSdk.csproj
SAVE_PROJECT_FILE="${PROJECT_FILE}.orig"
TEST_PACKAGE_DIR=./test-packages

mkdir -p "${TEST_PACKAGE_DIR}"

cp "${PROJECT_FILE}" "${SAVE_PROJECT_FILE}"

"$(dirname "$0")/update-version.sh" "${TEST_VERSION}"

trap 'mv "${SAVE_PROJECT_FILE}" "${PROJECT_FILE}"' EXIT

msbuild /restore

NUPKG_FILE="src/LaunchDarkly.XamarinSdk/bin/Debug/LaunchDarkly.XamarinSdk.${TEST_VERSION}.nupkg"
if [ -f "${NUPKG_FILE}" ]; then
mv "${NUPKG_FILE}" "${TEST_PACKAGE_DIR}"
echo; echo; echo "Success! Created test package version ${TEST_VERSION} in ${TEST_PACKAGE_DIR}"
else
echo; echo "Unknown problem - did not build the expected package file"
exit 1
fi
12 changes: 12 additions & 0 deletions scripts/update-version.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash

# update-version.sh <version string>
# Updates the version string in the project file.

NEW_VERSION="$1"

PROJECT_FILE=./src/LaunchDarkly.XamarinSdk/LaunchDarkly.XamarinSdk.csproj
TEMP_FILE="${PROJECT_FILE}.tmp"

sed "s#^\( *\)<Version>[^<]*</Version>#\1<Version>${NEW_VERSION}</Version>#g" "${PROJECT_FILE}" > "${TEMP_FILE}"
mv "${TEMP_FILE}" "${PROJECT_FILE}"
8 changes: 0 additions & 8 deletions src/LaunchDarkly.XamarinSdk/ClientRunMode.cs

This file was deleted.

23 changes: 9 additions & 14 deletions src/LaunchDarkly.XamarinSdk/Configuration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ public sealed class Configuration
private readonly int _eventCapacity;
private readonly Uri _eventsUri;
private readonly HttpMessageHandler _httpMessageHandler;
private readonly TimeSpan _httpClientTimeout;
private readonly bool _inlineUsersInEvents;
private readonly bool _isStreamingEnabled;
private readonly string _mobileKey;
Expand All @@ -43,7 +42,8 @@ public sealed class Configuration
private readonly TimeSpan _userKeysFlushInterval;

// Settable only for testing
internal readonly IConnectionManager _connectionManager;
internal readonly IBackgroundModeManager _backgroundModeManager;
internal readonly IConnectivityStateManager _connectivityStateManager;
internal readonly IDeviceInfo _deviceInfo;
internal readonly IEventProcessor _eventProcessor;
internal readonly IFlagCacheManager _flagCacheManager;
Expand Down Expand Up @@ -80,7 +80,7 @@ public sealed class Configuration
/// <summary>
/// The connection timeout to the LaunchDarkly server.
/// </summary>
public TimeSpan ConnectionTimeout { get; internal set; }
public TimeSpan ConnectionTimeout => _connectionTimeout;

/// <summary>
/// Whether to enable feature flag updates when the application is running in the background.
Expand Down Expand Up @@ -130,11 +130,6 @@ public sealed class Configuration
/// </summary>
public HttpMessageHandler HttpMessageHandler => _httpMessageHandler;

/// <summary>
/// The connection timeout. The default value is 10 seconds.
/// </summary>
public TimeSpan HttpClientTimeout => _httpClientTimeout;

/// <summary>
/// Sets whether to include full user details in every analytics event.
/// </summary>
Expand Down Expand Up @@ -216,7 +211,8 @@ public sealed class Configuration
/// encoded into the request URI. Using REPORT allows the user data to be sent in the request body instead.
/// However, some network gateways do not support REPORT.
/// </remarks>
public bool UseReport => _useReport;
internal bool UseReport => _useReport;
// UseReport is currently disabled due to Android HTTP issues (ch47341), but it's still implemented internally

/// <summary>
/// The number of user keys that the event processor can remember at any one time.
Expand Down Expand Up @@ -249,7 +245,6 @@ public sealed class Configuration
internal static readonly TimeSpan DefaultEventFlushInterval = TimeSpan.FromSeconds(5);
internal static readonly TimeSpan DefaultReadTimeout = TimeSpan.FromMinutes(5);
internal static readonly TimeSpan DefaultReconnectTime = TimeSpan.FromSeconds(1);
internal static readonly TimeSpan DefaultHttpClientTimeout = TimeSpan.FromSeconds(10);
internal static readonly int DefaultUserKeysCapacity = 1000;
internal static readonly TimeSpan DefaultUserKeysFlushInterval = TimeSpan.FromMinutes(5);
internal static readonly TimeSpan DefaultBackgroundPollingInterval = TimeSpan.FromMinutes(60);
Expand Down Expand Up @@ -328,7 +323,6 @@ internal Configuration(ConfigurationBuilder builder)
_eventCapacity = builder._eventCapacity;
_eventsUri = builder._eventsUri;
_httpMessageHandler = builder._httpMessageHandler;
_httpClientTimeout = builder._httpClientTimeout;
_inlineUsersInEvents = builder._inlineUsersInEvents;
_isStreamingEnabled = builder._isStreamingEnabled;
_mobileKey = builder._mobileKey;
Expand All @@ -344,7 +338,8 @@ internal Configuration(ConfigurationBuilder builder)
_userKeysCapacity = builder._userKeysCapacity;
_userKeysFlushInterval = builder._userKeysFlushInterval;

_connectionManager = builder._connectionManager;
_backgroundModeManager = builder._backgroundModeManager;
_connectivityStateManager = builder._connectivityStateManager;
_deviceInfo = builder._deviceInfo;
_eventProcessor = builder._eventProcessor;
_flagCacheManager = builder._flagCacheManager;
Expand All @@ -364,7 +359,7 @@ private class EventProcessorAdapter : IEventProcessorConfiguration
public int EventCapacity => Config.EventCapacity;
public TimeSpan EventFlushInterval => Config.EventFlushInterval;
public Uri EventsUri => Config.EventsUri;
public TimeSpan HttpClientTimeout => Config.HttpClientTimeout;
public TimeSpan HttpClientTimeout => Config.ConnectionTimeout;
public bool InlineUsersInEvents => Config.InlineUsersInEvents;
public IImmutableSet<string> PrivateAttributeNames => Config.PrivateAttributeNames;
public TimeSpan ReadTimeout => Config.ReadTimeout;
Expand All @@ -385,7 +380,7 @@ private class StreamManagerAdapter : IStreamManagerConfiguration
internal Configuration Config { get; set; }
public string HttpAuthorizationKey => Config.MobileKey;
public HttpMessageHandler HttpMessageHandler => Config.HttpMessageHandler;
public TimeSpan HttpClientTimeout => Config.HttpClientTimeout;
public TimeSpan HttpClientTimeout => Config.ConnectionTimeout;
public TimeSpan ReadTimeout => Config.ReadTimeout;
public TimeSpan ReconnectTime => Config.ReconnectTime;
}
Expand Down
86 changes: 46 additions & 40 deletions src/LaunchDarkly.XamarinSdk/ConfigurationBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ public interface IConfigurationBuilder
/// Sets the interval between feature flag updates when the application is running in the background.
/// </summary>
/// <remarks>
/// This is only relevant on mobile platforms.
/// This is only relevant on mobile platforms. The default is <see cref="Configuration.DefaultBackgroundPollingInterval"/>;
/// the minimum is <see cref="Configuration.MinimumPollingInterval"/>.
/// </remarks>
/// <param name="backgroundPollingInterval">the background polling interval</param>
/// <returns>the same builder</returns>
Expand All @@ -61,6 +62,30 @@ public interface IConfigurationBuilder
/// <returns>the same builder</returns>
IConfigurationBuilder BaseUri(Uri baseUri);

/// <summary>
/// Sets the connection timeout for all HTTP requests.
/// </summary>
/// <remarks>
/// The default value is 10 seconds.
/// </remarks>
/// <param name="connectionTimeout">the connection timeout</param>
/// <returns>the same builder</returns>
IConfigurationBuilder ConnectionTimeout(TimeSpan connectionTimeout);

/// <summary>
/// Sets whether to enable feature flag polling when the application is in the background.
/// </summary>
/// <remarks>
/// By default, on Android and iOS the SDK can still receive feature flag updates when an application
/// is in the background, but it will use polling rather than maintaining a streaming connection (and
/// will use <see cref="BackgroundPollingInterval(TimeSpan)"/> rather than <see cref="PollingInterval(TimeSpan)"/>).
/// If you set <c>EnableBackgroundUpdating</c> to false, it will not check for feature flag updates
/// until the application returns to the foreground.
/// </remarks>
/// <param name="enableBackgroundUpdating">true if background updating should be allowed</param>
/// <returns>the same builder</returns>
IConfigurationBuilder EnableBackgroundUpdating(bool enableBackgroundUpdating);

/// <summary>
/// Set to true if LaunchDarkly should provide additional information about how flag values were
/// calculated.
Expand Down Expand Up @@ -119,13 +144,6 @@ public interface IConfigurationBuilder
/// <returns>the same builder</returns>
IConfigurationBuilder HttpMessageHandler(HttpMessageHandler httpMessageHandler);

/// <summary>
/// Sets the connection timeout. The default value is 10 seconds.
/// </summary>
/// <param name="httpClientTimeout">the connection timeout</param>
/// <returns>the same builder</returns>
IConfigurationBuilder HttpClientTimeout(TimeSpan httpClientTimeout);

/// <summary>
/// Sets whether to include full user details in every analytics event.
/// </summary>
Expand Down Expand Up @@ -180,7 +198,8 @@ public interface IConfigurationBuilder
/// Sets the polling interval (when streaming is disabled).
/// </summary>
/// <remarks>
/// Values less than the default of 30 seconds will be changed to the default.
/// The default is <see cref="Configuration.DefaultPollingInterval"/>; the minimum is
/// <see cref="Configuration.MinimumPollingInterval"/>.
/// </remarks>
/// <param name="pollingInterval">the rule update polling interval</param>
/// <returns>the same builder</returns>
Expand Down Expand Up @@ -228,18 +247,6 @@ public interface IConfigurationBuilder
/// <returns>the same builder</returns>
IConfigurationBuilder StreamUri(Uri streamUri);

/// <summary>
/// Sets whether to use the HTTP REPORT method for feature flag requests.
/// </summary>
/// <remarks>
/// By default, polling and streaming connections are made with the GET method, witht the user data
/// encoded into the request URI. Using REPORT allows the user data to be sent in the request body instead.
/// However, some network gateways do not support REPORT.
/// </remarks>
/// <param name="useReport">whether to use REPORT mode</param>
/// <returns>the same builder</returns>
IConfigurationBuilder UseReport(bool useReport);

/// <summary>
/// Sets the number of user keys that the event processor can remember at any one time.
/// </summary>
Expand Down Expand Up @@ -269,14 +276,13 @@ internal sealed class ConfigurationBuilder : IConfigurationBuilder
internal bool _allAttributesPrivate = false;
internal TimeSpan _backgroundPollingInterval;
internal Uri _baseUri = Configuration.DefaultUri;
internal TimeSpan _connectionTimeout;
internal bool _enableBackgroundUpdating;
internal TimeSpan _connectionTimeout = Configuration.DefaultConnectionTimeout;
internal bool _enableBackgroundUpdating = true;
internal bool _evaluationReasons = false;
internal int _eventCapacity = Configuration.DefaultEventCapacity;
internal TimeSpan _eventFlushInterval = Configuration.DefaultEventFlushInterval;
internal Uri _eventsUri = Configuration.DefaultEventsUri;
internal HttpMessageHandler _httpMessageHandler = PlatformSpecific.Http.GetHttpMessageHandler(); // see Http.shared.cs
internal TimeSpan _httpClientTimeout = Configuration.DefaultHttpClientTimeout;
internal bool _inlineUsersInEvents = false;
internal bool _isStreamingEnabled = true;
internal string _mobileKey;
Expand All @@ -292,7 +298,8 @@ internal sealed class ConfigurationBuilder : IConfigurationBuilder
internal TimeSpan _userKeysFlushInterval = Configuration.DefaultUserKeysFlushInterval;

// Internal properties only settable for testing
internal IConnectionManager _connectionManager;
internal IBackgroundModeManager _backgroundModeManager;
internal IConnectivityStateManager _connectivityStateManager;
internal IDeviceInfo _deviceInfo;
internal IEventProcessor _eventProcessor;
internal IFlagCacheManager _flagCacheManager;
Expand All @@ -317,7 +324,6 @@ internal ConfigurationBuilder(Configuration copyFrom)
_eventFlushInterval = copyFrom.EventFlushInterval;
_eventsUri = copyFrom.EventsUri;
_httpMessageHandler = copyFrom.HttpMessageHandler;
_httpClientTimeout = copyFrom.HttpClientTimeout;
_inlineUsersInEvents = copyFrom.InlineUsersInEvents;
_isStreamingEnabled = copyFrom.IsStreamingEnabled;
_mobileKey = copyFrom.MobileKey;
Expand Down Expand Up @@ -407,12 +413,6 @@ public IConfigurationBuilder HttpMessageHandler(HttpMessageHandler httpMessageHa
return this;
}

public IConfigurationBuilder HttpClientTimeout(TimeSpan httpClientTimeout)
{
_httpClientTimeout = httpClientTimeout;
return this;
}

public IConfigurationBuilder InlineUsersInEvents(bool inlineUsersInEvents)
{
_inlineUsersInEvents = inlineUsersInEvents;
Expand Down Expand Up @@ -485,12 +485,6 @@ public IConfigurationBuilder StreamUri(Uri streamUri)
return this;
}

public IConfigurationBuilder UseReport(bool useReport)
{
_useReport = useReport;
return this;
}

public IConfigurationBuilder UserKeysCapacity(int userKeysCapacity)
{
_userKeysCapacity = userKeysCapacity;
Expand All @@ -509,9 +503,21 @@ public IConfigurationBuilder UserKeysFlushInterval(TimeSpan userKeysFlushInterva
// and then call these methods before you have called any of the public methods (since
// only these methods return ConfigurationBuilder rather than IConfigurationBuilder).

internal ConfigurationBuilder ConnectionManager(IConnectionManager connectionManager)
internal ConfigurationBuilder BackgroundModeManager(IBackgroundModeManager backgroundModeManager)
{
_backgroundModeManager = backgroundModeManager;
return this;
}

internal IConfigurationBuilder BackgroundPollingIntervalWithoutMinimum(TimeSpan backgroundPollingInterval)
{
_backgroundPollingInterval = backgroundPollingInterval;
return this;
}

internal ConfigurationBuilder ConnectivityStateManager(IConnectivityStateManager connectivityStateManager)
{
_connectionManager = connectionManager;
_connectivityStateManager = connectivityStateManager;
return this;
}

Expand Down
Loading