Skip to content

zu-java holds the misuse item - #577

Merged
tamnd merged 1 commit into
mainfrom
java-misuse
Aug 22, 2026
Merged

zu-java holds the misuse item#577
tamnd merged 1 commit into
mainfrom
java-misuse

Conversation

@tamnd

@tamnd tamnd commented Aug 22, 2026

Copy link
Copy Markdown
Owner

tamnd/zu-java#13 landed the misuse and lifecycle suite, so the scorecard says so.

MisuseTest is thirty four deliberately wrong programs in the shared cases module, which means both the Panama provider and the JNI provider run every one of them. Each row names what the caller did, the class it should raise and the sentence it should say. The text is asserted and not only the class, because a client that answers every mistake with zu_result_col_i64 answered MISUSE passes a class assertion and fails a user.

Six cases did not pass when the table was first written. A column read as the wrong type now names the column, what it holds and what the accessor reads. An appender whose connection closed under it says so instead of naming a C function. A result read after it closed refuses at the call rather than handing back a row that fails later. A file that is not a database is a connection error now rather than an internal one, because telling somebody who mistyped a path to open a bug is the wrong instruction. And the entry points name the parameter when it is null.

The lifecycle half takes the count of the process's own open file descriptors either side of five hundred failed opens, a thousand connections opened and closed, and a thousand failed statements. There is a companion test of the programs that look like misuse and are not, so none of this turns into a client that refuses ordinary work.

That is 45 to 60 on practice. What is left for zu-java is leaks, install and stability, which are apparatus, and api-map and perf, which are reports the release collects.

docs/clients/overview.md is regenerated by cargo run -q -p xtask -- clients and not hand-edited.

Thirty four deliberately wrong programs in the shared cases module, run by
both providers, each asserting the class it raises and the sentence it
says. Six of them did not pass when the table was first written, so the
same change fixes a column read as the wrong type, an appender whose
connection closed under it, a result read after it closed, a file that is
not a database being called an internal error, and the entry points that
took a null without naming the parameter. The lifecycle half counts open
file descriptors either side of five hundred failed opens, a thousand
connections and a thousand failed statements.

tamnd/zu-java#13. That takes the practice score to 60, and what is left is
leaks, install and stability, which are apparatus, and api-map and perf,
which are reports the release collects.
@tamnd
tamnd merged commit 099976c into main Aug 22, 2026
39 of 40 checks passed
@tamnd
tamnd deleted the java-misuse branch August 22, 2026 09:29
@tamnd tamnd mentioned this pull request Aug 22, 2026
22 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant