Repository navigation
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The Issue #783 test is enabled despite the PR description’s stated CI memory restriction, so the test annotation or description needs to be reconciled.
1 open issue
What changed in this PR
This PR revisits six inactive tests in the MarkLogic Java client’s core and functional suites, restoring regression coverage and removing obsolete cases.
Changes:
- Enables metadata-writing, metadata-streaming, and concurrent small-write tests with stronger assertions and cleanup.
- Sequences bitemporal transactions to avoid lock contention and verify protection behavior.
- Removes duplicate concurrent-write and unsupported transaction-size tests.
| File | Description |
|---|---|
| marklogic-client-api/src/test/java/com/marklogic/client/test/io/DocumentMetadataHandleTest.java | Enables the #783 streaming regression and adds metadata checks and cleanup. |
| marklogic-client-api/src/test/java/com/marklogic/client/test/datamovement/WriteBatcherTest.java | Restores #646 coverage with callback tracking and persisted metadata assertions. |
| marklogic-client-api-functionaltests/src/test/java/com/marklogic/client/functionaltest/TestBiTempMetaValues.java | Restores temporal-protection coverage with sequential commits and rollback cleanup. |
| marklogic-client-api-functionaltests/src/test/java/com/marklogic/client/datamovement/functionaltests/WriteHostBatcherTest.java | Restores concurrent small-write coverage with bounded waits and removes two obsolete tests. |
Review effort: Balanced
| // testing https://github.com/marklogic/java-client-api/issues/783 | ||
| // @Test | ||
| @Disabled | ||
| @Test |
prgs-rsingh
left a comment
There was a problem hiding this comment.
All 4 restored tests (testIssue646, testStack20170725, testAddMultiThreadedLessDocsSuccess, and testProtectUpdateInDiffTransactions) have proper assertions, bounded waits, and finally / try-with-resources cleanup for jobs, executors, streams, DocumentPages, and transactions, and the 2 obsolete/duplicate WriteHostBatcherTest methods are cleanly removed.

Summary
WriteBatcherTest.java (Issue Loading document fails when used with a MetaData object with property set #646)
@Testannotation.DocumentMetadataHandleTest.java (Issue Cannot stream when retrieving metadata #783)
@Disabledwith@Testdue to CI memory limitations.WriteHostBatcherTest.java (Small-write test)
@Testto validate concurrent writes from 3 producers (45 documents).WriteHostBatcherTest.java (Issue Create an easy-to-use API to specify Projections & Snippets for search #62)
WriteHostBatcherTest.java (Issue B3 0 #58)
withTransactionSizeis no longer supported.TestBiTempMetaValues.java (Issue Doc write in a transaction and protect in another transaction causes an application to hang #542)
@Testand fixed the transaction deadlock.TEMPORAL-PROTECTEDerror.Verification
./gradlew clean compileJava compileTestJavapassed with zero warnings.@Disabledannotations remain without@Test.