Add ai-21-migration module: upgrading Spring AI 2.0.x to 2.1.0, measured. One probe source tree run on 2.0.0, 2.0.2, 2.0.3 and 2.1.0 (Anthropic prompt tokens with caching, auth header, discarded temperature, thinking parts, message mutability, entity() on refusals), three compile breaks, API and configuration diffs from the jars, ChatMemory to session copy, a wrapping ToolCallingManager under tool confirmation, the OpenAI Responses switch, VectorStore.upsert on real pgvector, a grep checklist and an OpenRewrite recipe. Scripted and local fake models; no provider called. Spring Boot 4.2.0, Spring AI 2.1.0, Java 25.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017ic4b7N4ZDbUtA3ofqAqRV
This commit is contained in:
Executable
+22
@@ -0,0 +1,22 @@
|
||||
#!/usr/bin/env bash
|
||||
# Compile each file in broken/src against 2.0.3 and 2.1.0 and keep javac's own words.
|
||||
set -euo pipefail
|
||||
cd "$(dirname "$0")/.."
|
||||
out=output/07-compile-breaks.txt
|
||||
echo "# javac on broken/src/*.java against two Spring AI versions" > "$out"
|
||||
for pair in 2.0.3:4.1.0 2.1.0:4.2.0; do
|
||||
v=${pair%:*}
|
||||
(cd probes && mvn -B -q dependency:build-classpath -Dspring-ai.version="$v" -Dboot.version="${pair#*:}" -Dmdep.outputFile="target/cp-$v.txt" >/dev/null 2>&1)
|
||||
cp=$(cat "probes/target/cp-$v.txt")
|
||||
echo >> "$out"; echo "== Spring AI $v" >> "$out"
|
||||
for f in broken/src/*.java; do
|
||||
tmp=$(mktemp -d)
|
||||
if msg=$(javac -J-Duser.language=en -proc:none -d "$tmp" -cp "$cp" "$f" 2>&1); then
|
||||
echo "$(basename "$f"): compiles" >> "$out"
|
||||
else
|
||||
echo "$(basename "$f"): FAILS" >> "$out"
|
||||
echo "$msg" | grep -v -e 'Picked up' | grep -e 'error:' -e 'symbol:' | sed -e "s#^$f# $(basename "$f")#" -e 's/^ *symbol:/ symbol:/' >> "$out"
|
||||
fi
|
||||
done
|
||||
done
|
||||
cat "$out"
|
||||
Reference in New Issue
Block a user