Search arXiv⌕ Search

arXiv · 2612.04651

Isolation-Aware Migration from Legacy Relational Databases to Distributed SQL: Measuring and Containing Transaction Retry Risk in AI-Assisted Modernization

Abstract

Large language models (LLMs) are increasingly used to translate schemas and procedural code when enterprises migrate from single-node relational databases to distributed SQL systems. Translation, however, addresses only syntax. When the target uses optimistic, serializable concurrency control, applications written for lock-based read-committed isolation encounter serialization aborts that the original code never handled, and these failures surface under production contention rather than in functional testing. We treat this behavioral gap as a first-class migration concern. We propose eight architecture patterns that wrap probabilistic LLM translation in deterministic verification, and we integrate them into a reference architecture whose cutover is governed by service level objectives. We then evaluate the behavioral core empirically. On a single-hot-row read-modify-write microbenchmark at 32 concurrent clients, two serializable configurations abort 79-86% of transaction attempts. A read-committed configuration aborts none, but for this code it permits lost updates. Welch tests show that the gap between serializable and read-committed isolation is significant from four clients upward. The two serializable engines differ by a smaller, though significant, 6-9 percentage points. Aborts vanish when clients stop sharing rows. A bounded retry envelope converts almost all aborts into commits, at a 5.5-fold throughput cost relative to read committed. On a mixed workload, unmodified code exposes application-visible failures in 11-28% of transactions. Wrapping scanner-flagged transactions in the envelope removes 99.3% of these failures, with a throughput cost that is significant only at 32 clients. A heuristic isolation risk scanner classifies all 21 objects of a small author-built corpus correctly; the 95% confidence interval for its recall is 0.74-1.00.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Sharath Chandra Kampili. 2026-12-02. Isolation-Aware Migration from Legacy Relational Databases to Distributed SQL: Measuring and Containing Transaction Retry Risk in AI-Assisted Modernization. https://searcharxiv.org/abs/2612.04651

Citations retain the original authors and DOI and include this site’s record URL. If this discovery service contributed to your research, you can also cite Search arXiv by Indiciae: BibTeX · RIS.

KEEP EXPLORING

Related papers

ABISS: Evaluating Text-to-SQL Systems Through Agent Interaction

Real-world users frequently pose ambiguous or unanswerable questions that current Large Language Model (LLM)-based Text-to-SQL systems handle poorly. Three interconnected gaps hinder progress: incomplete taxonomies, the lack of scalable generation of realistic benchmark data, and evaluation limited to fixed, idealized conversations. We address these gaps through three contributions: (1) a unified taxonomy of 8 categories covering ambiguous and unanswerable questions; (2) a multi-agent generation pipeline that generates Natural Language Questions (NLQs), grounds them in SQL, and applies a ten-stage validation pipeline with council-based checks; and (3) ABISS (Ambiguity Benchmark using Interaction-Simulated Sessions), a dynamic simulation environment where Text-to-SQL agents interact with style-aware simulated users across multi-turn dialogues. Experiments with ten models, nine of them open-source, on BIRD- and Spider-based datasets reveal two bottlenecks. First, models often fail to recognize that a question is ambiguous, although they usually name its subcategory correctly once they do, and the correct label helps mostly on the questions whose type they miss. Second, models lose most when they answer without asking: once the simulated user supplies the missing information, their SQL is nearly as accurate as when it is given in advance. We release our code and a link to the datasets on GitHub (https://github.com/giosullutrone/ABISS-Evaluating-Text-to-SQL-Systems-Through-Agent-Interaction).

cs.DB↗

Where Should the Vectors Live? Locality-Aware Retrieval for RAG on Geo-Distributed SQL

Enterprise retrieval-augmented generation (RAG) increasingly runs vector search inside geo-distributed SQL databases, where the corpus is fresh, transactional, and subject to data-residency rules. Where the vectors live relative to their users then decides retrieval latency, freshness, and compliance. We compare five placement strategies on a three-region deployment of a commercially available geo-distributed SQL database with emulated wide-area latency and its native vector index: a centralized table, follower reads, a global table, and home-region partitioning searched globally or locally. The workload is 20,963 SQuAD passages with real questions. Approximate nearest neighbor search amplifies network distance: a remote top-10 query costs 4.2 round trips beyond its local cost, so medians span 6.4 ms to over 700 ms (112x) across strategies that differ only in placement. Local strategies pay elsewhere, in staleness, write latency, or missed answers. We propose LARR, a locality-aware retrieval router that searches the home partition first and escalates to a cross-region fan-out only when the best local distance exceeds a calibrated threshold. With 90% of questions issued from the answer's home region, LARR matches the fan-out's hit@10 (70.7% vs. 70.5%; 95% CI of the difference [-1.4, +1.9] points) at 5.9x lower mean latency. The result holds live on held-out questions, with production-style three-node-per-region replication, and on three real cloud regions (6.1x). With a second, transformer-based embedding model, LARR matches the fan-out at 3.5x lower latency, and its throughput advantage persists under concurrent load. A replicated centroid sketch (LARR-S) sharpens escalation when locality is weaker. We also report a pitfall with partitioned vector indexes.

cs.DB↗

Refetch times of AI crawlers: a paired comparison with Googlebot

AI answer engines learn about the web through three types of crawlers: training crawlers collect pages for future models, search crawlers keep the engine's index up-to-date, and user fetchers retrieve a page when a user's prompt triggers it. When a publisher changes a page, an answer engine can show the change only after one of these crawlers fetches the page again. Previous works have analyzed request counts and distinct pages, but none have measured how long a crawler takes to refetch a page. In this work, we measure the refetch time of ten crawlers (including eight AI crawlers) on Prerender customer sites using a Kaplan-Meier survival analysis, and compare it with Googlebot on the same domains in the same months. Googlebot fetched half of its pages again within 13 days on a typical customer's site. AI search crawlers are slower: OpenAI's took 28 days and Perplexity's more than 90. Training crawlers differ by operator, from 6 days for Meta's to 46 for Anthropic's and 66 for OpenAI's. User fetchers come back as often as users ask: OpenAI's took 10 days. A bootstrap and a sign test over customer accounts find these gaps significant, and they survive our robustness checks. We conclude that a change to a page can take weeks longer to reach AI search indexes than to reach Google's, and one and a half to two months to reach OpenAI's and Anthropic's training crawlers, which matters to every publisher whose prices, stock or facts change.

cs.DB↗