This is an automated email from the ASF dual-hosted git repository.
sergehuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/unomi.git
The following commit(s) were added to refs/heads/master by this push:
new 7c87fb0bb UNOMI-1019: Bundle the web tracker from its 2.0 development
line (#934)
7c87fb0bb is described below
commit 7c87fb0bbbc8a6d1d19c67ef311aae58e49e21d6
Author: Serge Huber <[email protected]>
AuthorDate: Thu Nov 12 08:45:53 2026 +0100
UNOMI-1019: Bundle the web tracker from its 2.0 development line (#934)
Co-authored-by: Claude Opus 5.5 <[email protected]>
---
extensions/web-tracker/wab/package.json | 2 +-
extensions/web-tracker/wab/pom.xml | 41 ++++++++++++++++++++++
.../web-tracker/wab/src/main/webapp/index.html | 7 ++--
extensions/web-tracker/wab/yarn.lock | 11 +++---
4 files changed, 52 insertions(+), 9 deletions(-)
diff --git a/extensions/web-tracker/wab/package.json
b/extensions/web-tracker/wab/package.json
index c75d824d5..28adae7dd 100644
--- a/extensions/web-tracker/wab/package.json
+++ b/extensions/web-tracker/wab/package.json
@@ -13,7 +13,7 @@
"build": "yarn rollup --config"
},
"dependencies": {
- "apache-unomi-tracker": "^1.1.0"
+ "apache-unomi-tracker":
"git+https://github.com/apache/unomi-tracker.git#a590b71843c446d38ca87b07337fc6546c01833c"
},
"devDependencies": {
"@babel/core": "^7.24.0",
diff --git a/extensions/web-tracker/wab/pom.xml
b/extensions/web-tracker/wab/pom.xml
index f7284176e..91006af01 100644
--- a/extensions/web-tracker/wab/pom.xml
+++ b/extensions/web-tracker/wab/pom.xml
@@ -78,6 +78,12 @@
<goals>
<goal>yarn</goal>
</goals>
+ <configuration>
+ <!-- The tracker is a git dependency: its prepare
script runs a nested yarn
+ install that shares the yarn cache, and
parallel downloads into that
+ cache corrupt it on a cold CI cache. -->
+ <arguments>install --frozen-lockfile
--network-concurrency 1</arguments>
+ </configuration>
</execution>
<execution>
<id>yarn build</id>
@@ -104,4 +110,39 @@
</plugin>
</plugins>
</build>
+
+ <profiles>
+ <profile>
+ <!-- Active for every Apache release build. A Unomi release must
bundle a tracker release
+ voted by the PMC, not a commit of apache/unomi-tracker. -->
+ <id>apache-release</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>require-released-tracker</id>
+ <phase>validate</phase>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ <configuration>
+ <target>
+ <loadfile property="trackerPackage"
srcFile="${project.basedir}/package.json" />
+ <fail message="package.json depends on
a commit of apache-unomi-tracker. A release must use a voted tracker release,
for example "^2.0.0".">
+ <condition>
+ <contains
string="${trackerPackage}" substring="unomi-tracker.git#" />
+ </condition>
+ </fail>
+ </target>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
</project>
diff --git a/extensions/web-tracker/wab/src/main/webapp/index.html
b/extensions/web-tracker/wab/src/main/webapp/index.html
index 16d1c93e5..b0d419c6e 100644
--- a/extensions/web-tracker/wab/src/main/webapp/index.html
+++ b/extensions/web-tracker/wab/src/main/webapp/index.html
@@ -45,14 +45,17 @@
},
"consentTypes": []
},
- "events:": [],
+ "events": [],
"wemInitConfig": {
"contextServerUrl": document.location.origin,
"timeoutInMilliseconds": "1500",
"contextServerCookieName": "context-profile-id",
"activateWem": true,
"trackerSessionIdCookieName":
"unomi-tracker-test-session-id",
- "trackerProfileIdCookieName":
"unomi-tracker-test-profile-id"
+ "trackerProfileIdCookieName":
"unomi-tracker-test-profile-id",
+ // Tenant public API key, needed unless single-tenant
compatibility mode is on.
+ // For this sample page, pass it in the URL:
/tracker/?apiKey=YOUR_PUBLIC_API_KEY
+ "apiKey": new
URLSearchParams(document.location.search).get("apiKey") || undefined
}
}
diff --git a/extensions/web-tracker/wab/yarn.lock
b/extensions/web-tracker/wab/yarn.lock
index c467b52f8..830d06c82 100644
--- a/extensions/web-tracker/wab/yarn.lock
+++ b/extensions/web-tracker/wab/yarn.lock
@@ -816,7 +816,7 @@
"@babel/types" "^7.4.4"
esutils "^2.0.2"
-"@babel/[email protected]", "@babel/runtime@^7.18.9":
+"@babel/[email protected]", "@babel/runtime@^7.26.10":
version "7.29.7"
resolved
"https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.29.7.tgz#12022450c45a4da6d8d8287b18a4ff2ddb23f768"
integrity
sha512-Nq8OhGWiZIZGV6hLHoyAKLLcJihP/xFeBMGJoUrxTX2psI8dCifzLhZISFb+VWS3wFMRDmCGw5R+dOySCqPLhw==
@@ -1019,12 +1019,11 @@ ansi-styles@^3.2.1:
dependencies:
color-convert "^1.9.0"
-apache-unomi-tracker@^1.1.0:
- version "1.4.0"
- resolved
"https://registry.yarnpkg.com/apache-unomi-tracker/-/apache-unomi-tracker-1.4.0.tgz#50707986531fc4f5dec28cdf06a18e48610bcb78"
- integrity
sha512-5mYm1GQDrzUNxYcQymmGYYkk7AKjGakI5T3wUH4apjiRzKwPMiMyRvc45HvYNmcCGZoPlP1AEcimVu+2t0M7PA==
+"apache-unomi-tracker@git+https://github.com/apache/unomi-tracker.git#a590b71843c446d38ca87b07337fc6546c01833c":
+ version "2.0.0"
+ resolved
"git+https://github.com/apache/unomi-tracker.git#a590b71843c446d38ca87b07337fc6546c01833c"
dependencies:
- "@babel/runtime" "^7.18.9"
+ "@babel/runtime" "^7.26.10"
es6-crawler-detect "^3.3.0"
atob@^2.1.2: