Rename CLI_ASYNC_DDL to DDL_EXECUTION_MODE enum variable
Context
Part of #47 (java-spanner/go-sql-spanner compatibility). Currently CLI_ASYNC_DDL is a boolean variable that doesn't match upstream naming or behavior.
Upstream References
- go-sql-spanner v1.24.0 (
connection_properties.go:328-389): ddl_execution_mode enum (SYNC/ASYNC/ASYNC_WAIT) + ddl_async_wait_timeout (default 10s)
- java-spanner:
ddlExecutionMode connection-time property
Changes Required
Variable Rename and Type Change
- Rename
CLI_ASYNC_DDL (bool) → DDL_EXECUTION_MODE (enum: SYNC, ASYNC, ASYNC_WAIT)
- SYNC = current
false (default)
- ASYNC = current
true
- ASYNC_WAIT = new mode (wait for DDL completion with timeout)
New Companion Variable
- Add
DDL_ASYNC_WAIT_TIMEOUT duration variable (default 10s, per go-sql-spanner)
- Only effective when
DDL_EXECUTION_MODE = ASYNC_WAIT
CLI Flag Update
- Update
--async CLI flag to map to DDL_EXECUTION_MODE = ASYNC
Backward Compatibility
- No backward compatibility required per project philosophy
Acceptance Criteria
Rename
CLI_ASYNC_DDLtoDDL_EXECUTION_MODEenum variableContext
Part of #47 (java-spanner/go-sql-spanner compatibility). Currently
CLI_ASYNC_DDLis a boolean variable that doesn't match upstream naming or behavior.Upstream References
connection_properties.go:328-389):ddl_execution_modeenum (SYNC/ASYNC/ASYNC_WAIT) +ddl_async_wait_timeout(default 10s)ddlExecutionModeconnection-time propertyChanges Required
Variable Rename and Type Change
CLI_ASYNC_DDL(bool) →DDL_EXECUTION_MODE(enum: SYNC, ASYNC, ASYNC_WAIT)false(default)trueNew Companion Variable
DDL_ASYNC_WAIT_TIMEOUTduration variable (default 10s, per go-sql-spanner)DDL_EXECUTION_MODE = ASYNC_WAITCLI Flag Update
--asyncCLI flag to map toDDL_EXECUTION_MODE = ASYNCBackward Compatibility
Acceptance Criteria
SET DDL_EXECUTION_MODE = 'SYNC'/'ASYNC'/'ASYNC_WAIT'worksSHOW VARIABLE DDL_EXECUTION_MODEworksSET DDL_ASYNC_WAIT_TIMEOUT = '30s'worksSHOW VARIABLE DDL_ASYNC_WAIT_TIMEOUTworks--asyncCLI flag sets mode to ASYNCCLI_ASYNC_DDLis fully removedmake checkpasses