diff --git a/README.md b/README.md index 34a9563..06e1c2e 100644 --- a/README.md +++ b/README.md @@ -1,21 +1,21 @@ -# CumulocityCoreLibrary +# cumulocity-clients-kotlin ## Usage To link the module into your Android application, modify your `settings.gradle` and your `gradle` build file as described below. -1. In `settings.gradle`, include the module `CumulocityCoreLibrary`. Optionally, you can reference the source code by linking the `projectDir` relative to your module's root directory. +1. In `settings.gradle`, include the module `cumulocity-clients-kotlin`. Optionally, you can reference the source code by linking the `projectDir` relative to your module's root directory. ```groovy -include ':CumulocityCoreLibrary' -project(":CumulocityCoreLibrary").projectDir = new File(rootDir, "relative to your projects dir/CumulocityCoreLibrary") +include ':cumulocity-clients-kotlin' +project(":cumulocity-clients-kotlin").projectDir = new File(rootDir, "relative to your projects dir/cumulocity-clients-kotlin") ``` 2. Add the module dependency to your applications `build` file: ```groovy dependencies { - implementation project(':CumulocityCoreLibrary') + implementation project(':cumulocity-clients-kotlin') } ``` @@ -35,7 +35,7 @@ buildscript { ### Use your own domain model -The CumulocityCoreLibrary allows custom data models. The following classes are designed to be extensible: +The cumulocity-clients-kotlin allows custom data models. The following classes are designed to be extensible: - `Alarm`, `AuditRecord`, `CategoryOptions`, `CustomProperties`, `Event`, `ManagedObject`, `Measurement`, `Operation` diff --git a/build-jar.gradle b/build-jar.gradle index 6821f4c..a01965f 100644 --- a/build-jar.gradle +++ b/build-jar.gradle @@ -4,8 +4,8 @@ plugins { } jar { - archiveBaseName = 'cumulocitycorelibrary' - archiveVersion = '-266' + archiveBaseName = 'cumulocity-clients-kotlin' + archiveVersion = '-268' } repositories { diff --git a/build.gradle b/build.gradle index e7301bc..4069968 100644 --- a/build.gradle +++ b/build.gradle @@ -26,12 +26,18 @@ android { defaultConfig { minSdkVersion 19 targetSdkVersion 33 - versionCode 266 + versionCode 268 versionName "" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } + libraryVariants.all { variant -> + variant.packageLibraryProvider.configure { task -> + task.archiveFileName.set("cumulocity-clients-kotlin-${variant.name}-${defaultConfig.versionName}-${defaultConfig.versionCode}.aar") + } + } + buildTypes { release { minifyEnabled true diff --git a/src/main/java/com/cumulocity/client/api/DeviceStatisticsApi.kt b/src/main/java/com/cumulocity/client/api/DeviceStatisticsApi.kt index f6070ae..837c4a0 100644 --- a/src/main/java/com/cumulocity/client/api/DeviceStatisticsApi.kt +++ b/src/main/java/com/cumulocity/client/api/DeviceStatisticsApi.kt @@ -48,6 +48,14 @@ import com.cumulocity.client.model.DeviceStatisticsCollection * #### When I have a device with children are the requests counted always to the root device or separately for each child? * * Separately for each child. + * + * #### Why do device statistics show significantly smaller request numbers than the total number of created and updated request from usage statistics? + * + * The important aspect here is the moment of recording values for the counters. For inbound data usage statistics we count every request that passed authorization, including invalid requests, as stated in usage statistics description. + * + * For device statistics it is different. We count requests after data is successfully stored in the database (or transient), which means the request was valid and there was no problem with persistence. + * + * In summary, if you observe that your usage statistics counters are significantly larger than your device statistics counters, there is a good chance that some devices or microservices in your tenant are constantly sending invalid requests. In such a situation, the client should check the state of theirs tenant. */ interface DeviceStatisticsApi {