From 4f10ea2001042916531a410ef1c54f9345b312fc Mon Sep 17 00:00:00 2001 From: Tung Vu <53031642+tung-vu-td@users.noreply.github.com> Date: Thu, 11 Jul 2024 11:54:40 +0700 Subject: [PATCH] Release version 1.1.0 (#89) --- CHANGELOG.md | 5 ++ README.md | 60 ++++++++++++------- build.gradle | 6 +- .../treasuredata/android/TreasureData.java | 2 +- 4 files changed, 46 insertions(+), 27 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7fd732e..9c3affe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Change Log +## Version 1.1.0 +_2024-07-10_ + +* New APIs enableAutoTrackingIP and disableAutoTrackingIP to track device’s IP in td_ip column + ## Version 1.0.1 _2024-05-30_ diff --git a/README.md b/README.md index 3084133..641a9e9 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ Version 1 has major changes that are not backward compatible with previous versi - Server side upload timestamp feature is removed. - New `enableAutoAppendLocalTimestamp` and `disableAutoAppendLocalTimestamp` APIs to help automatically track local timestamp. - `uuid` is now reserved column name. If you try to add value to event's `uuid` key, you won't see the column show up in the database. -- Auto tracking of client id by adding `td_ip` field is no longer supported. +- Auto tracking of client id by adding `td_ip` field is no longer supported. Instead, use new `enableAutoTrackingIP` and `disableAutoTrackingIP` APIs. ## Installation @@ -24,7 +24,7 @@ If you use gradle, add the following dependency to `dependencies` directive in t ``` dependencies { - implementation 'com.treasuredata:td-android-sdk:1.0.1' + implementation 'com.treasuredata:td-android-sdk:1.1.0' } ``` @@ -36,7 +36,7 @@ If you use maven, add the following directives to your pom.xml com.treasuredata td-android-sdk - 1.0.1 + 1.1.0 ``` @@ -485,6 +485,20 @@ It outputs the following column names and values: - `td_locale_country` : java.util.Locale.getCountry() (from Context.getResources().getConfiguration().locale) - `td_locale_lang` : java.util.Locale.getLanguage() (from Context.getResources().getConfiguration().locale) +### Auto tracking device IP + +Device IP will be added to each event automatically in `td_ip` column if you call `enableAutoTrackingIP`. Note that the tracked IP address is the one when you upload the events to Treasure Data, not the one when you add the event. + +``` +[[TreasureData sharedInstance] enableAutoTrackingIP]; +``` + +To disable auto tracking IP: + +``` +[[TreasureData sharedInstance] disableAutoTrackingIP]; +``` + ### Profiles API Lookup for profiles via [Profiles API](https://docs.treasuredata.com/display/public/PD/Working+with+Profiles+and+the+Profiles+API+Tokens) @@ -526,24 +540,24 @@ TreasureData.sharedInstance().fetchUserSegments(Arrays.asList("