This is an automated email from the ASF dual-hosted git repository.

asf-gitbox-commits pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/sis.git

commit 260a742c08167cf859e1202f91bdd631914d06f2
Merge: 83c629cdbb 80c161ba8d
Author: Martin Desruisseaux <[email protected]>
AuthorDate: Wed Aug 19 18:50:23 2026 +0200

    Merge branch 'geoapi-3.1'.
    Contains migration of default database from Derby to HSQLDB.
    https://issues.apache.org/jira/browse/SIS-631

 .../buildtools/coding/VerifyVersionInJavadoc.java  |   6 +-
 .../apache/sis/buildtools/gradle/Dependency.java   |  16 +--
 .../sis/buildtools/gradle/ModularPublishing.java   |   6 +-
 .../apache/sis/buildtools/gradle/ModularTest.java  |   2 +-
 .../org/apache/sis/buildtools/gradle/UnoPkg.java   |   2 +-
 .../org/apache/sis/buildtools/maven/Generator.java |   6 +-
 endorsed/build.gradle.kts                          |   5 +-
 .../main/org/apache/sis/console/Command.java       |  10 +-
 .../main/org/apache/sis/image/ComputedTiles.java   |   2 +-
 .../apache/sis/metadata/sql/MetadataSource.java    |   7 +-
 .../apache/sis/metadata/sql/MetadataWriter.java    |   2 +-
 .../sis/metadata/sql/internal/shared/Dialect.java  |   8 ++
 .../metadata/sql/internal/shared/Initializer.java  |  58 +++++------
 .../sql/internal/shared/LocalDataSource.java       |  16 +--
 .../metadata/sql/internal/shared/ScriptRunner.java |  70 ++++++++++---
 .../metadata/sql/internal/shared/TypeMapper.java   |   4 +-
 .../org/apache/sis/util/iso/DefaultRecordType.java |   2 +
 .../org/apache/sis/util/iso/DefaultTypeName.java   |   1 +
 .../sis/metadata/sql/IdentifierGeneratorTest.java  |   1 +
 .../sis/metadata/sql/MetadataFallbackVerifier.java |   1 +
 .../sis/metadata/sql/MetadataSourceTest.java       |  15 ++-
 .../sis/metadata/sql/MetadataWriterTest.java       |  55 ++++++----
 .../org/apache/sis/metadata/sql/TestDatabase.java  |  26 +++--
 .../sql/internal/shared/ScriptRunnerTest.java      |  30 ++++--
 .../apache/sis/referencing/IdentifiedObjects.java  |   7 +-
 .../factory/IdentifiedObjectFinder.java            |   2 +-
 .../referencing/factory/sql/EPSGCodeFinder.java    |   9 +-
 .../referencing/factory/sql/EPSGDataAccess.java    |   2 +-
 .../sis/referencing/factory/sql/EPSGFactory.java   |  11 +-
 .../sis/referencing/factory/sql/EPSGInstaller.java |  26 +++--
 .../sis/referencing/factory/sql/package-info.java  |  22 ++--
 .../operation/AbstractCoordinateOperation.java     | 111 ++++++++++++++-------
 .../operation/AbstractSingleOperation.java         |   7 +-
 .../referencing/operation/DefiningConversion.java  |  69 +++++++++++++
 .../operation/transform/MolodenskyTransform.java   |   3 +-
 .../org/apache/sis/referencing/CommonCRSTest.java  |  24 ++++-
 .../sis/referencing/factory/TestFactorySource.java |   3 +-
 .../referencing/factory/sql/EPSGInstallerTest.java |   2 +-
 .../transform/DefaultMathTransformFactoryTest.java |   2 +-
 .../sis/storage/geotiff/writer/GeoEncoder.java     |  66 ++++++++----
 .../apache/sis/storage/sql/SimpleFeatureStore.java |   1 +
 .../apache/sis/storage/sql/feature/Analyzer.java   |  17 +++-
 .../org/apache/sis/storage/sql/DataAccessTest.java |  17 +++-
 .../apache/sis/storage/sql/TestOnAllDatabases.java |   3 +-
 .../storage/sql/feature/InfoStatementsTest.java    |   6 +-
 .../sql/feature/SelectionClauseWriterTest.java     |  71 ++++++++++---
 .../org/apache/sis/io/stream/ChannelDataInput.java |   1 +
 .../sis/storage/esri/AsciiGridStoreTest.java       |  12 +--
 .../main/org/apache/sis/setup/Configuration.java   |  30 +++---
 .../main/org/apache/sis/system/Reflect.java        |   2 +-
 .../org/apache/sis/util/collection/CacheTest.java  |  16 +--
 netbeans-project/ivy.xml                           |   8 +-
 optional/build.gradle.kts                          |   5 +-
 optional/src/org.apache.sis.gui/bundle/bin/sis     |   1 -
 optional/src/org.apache.sis.gui/bundle/bin/sis.bat |   1 -
 optional/src/org.apache.sis.gui/bundle/bin/sisfx   |   1 -
 .../src/org.apache.sis.gui/bundle/bin/sisfx.bat    |   1 -
 optional/src/org.apache.sis.gui/bundle/lib/README  |   2 +-
 optional/src/org.apache.sis.gui/bundle/log/README  |   3 +-
 .../apache/sis/gui/coverage/IsolineController.java |   2 +-
 .../apache/sis/gui/coverage/TileMatrixSetPane.java |   1 -
 .../org/apache/sis/gui/dataset/FeatureTable.java   |   1 -
 .../apache/sis/gui/dataset/ResourceExplorer.java   |   1 -
 .../main/module-info.java                          |   6 +-
 .../sis/resources/embedded/EmbeddedResources.java  |  16 +--
 .../sis/resources/embedded/package-info.java       |   4 +-
 .../resources/embedded/EmbeddedResourcesTest.java  |   2 +-
 .../apache/sis/resources/embedded/Generator.java   |  61 ++---------
 .../main/module-info.java                          |   4 +-
 .../sis/referencing/factory/sql/epsg/README.md     |   4 +-
 .../org/apache/sis/storage/gdal/GDALStore.java     |   2 +-
 settings.gradle.kts                                |   5 +-
 72 files changed, 662 insertions(+), 362 deletions(-)

diff --cc 
endorsed/src/org.apache.sis.metadata/test/org/apache/sis/metadata/sql/MetadataWriterTest.java
index 5e02230ec5,8b32fd562c..720fc6a676
--- 
a/endorsed/src/org.apache.sis.metadata/test/org/apache/sis/metadata/sql/MetadataWriterTest.java
+++ 
b/endorsed/src/org.apache.sis.metadata/test/org/apache/sis/metadata/sql/MetadataWriterTest.java
@@@ -84,18 -91,26 +88,27 @@@ public final class MetadataWriterTest e
       */
      @Test
      @ResourceLock(TestDatabase.POSTGRESQL)
 +    @org.junit.jupiter.api.Disabled("Requires GeoAPI 3.1.")
-     public void testPostgreSQL() throws Exception {
+     public void testOnPostgreSQL() throws Exception {
          try (final TestDatabase db = 
TestDatabase.createOnPostgreSQL("MetadataWriter", true)) {
-             source = new MetadataWriter(MetadataStandard.ISO_19115, 
db.source, "MetadataWriter", null);
-             try {
-                 write();
-                 search();
-                 read();
-                 readWriteDeprecated();
-             } finally {
-                 source.close();
-             }
+             run(db, "MetadataWriter");
+         }
+     }
+ 
+     /**
+      * Runs all tests in the required order.
+      *
+      * @throws Exception if an error occurred while writing or reading the 
database.
+      */
+     private void run(final TestDatabase db, final String schema) throws 
Exception {
+         source = new MetadataWriter(MetadataStandard.ISO_19115, db.source, 
schema, null);
+         try {
+             write();
+             search();
+             read();
+             readWriteDeprecated();
+         } finally {
+             source.close();
          }
      }
  
diff --cc 
endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/AbstractCoordinateOperation.java
index 8dd2fba967,e430110534..af8037858f
--- 
a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/AbstractCoordinateOperation.java
+++ 
b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/AbstractCoordinateOperation.java
@@@ -942,11 -891,20 +954,20 @@@ check:      for (int isTarget=0; ; isTa
                   *   - Scope, domain and accuracy properties only if NOT in 
"ignore metadata" mode.
                   *   - Interpolation CRS in all cases (regardless if ignoring 
metadata or not).
                   */
-                 final var that = (CoordinateOperation) object;
+                 CoordinateOperation that = (CoordinateOperation) object;
                  if ((mode.isIgnoringMetadata() ||
-                     (deepEquals(getCoordinateOperationAccuracy(), 
that.getCoordinateOperationAccuracy(), mode))) &&
-                      deepEquals(getInterpolationCRS().orElse(null), 
getInterpolationCRS(that), mode))
+                     (Utilities.deepEquals(getCoordinateOperationAccuracy(), 
that.getCoordinateOperationAccuracy(), mode))) &&
 -                     Utilities.deepEquals(getInterpolationCRS(), 
that.getInterpolationCRS(), mode))
++                     Utilities.deepEquals(getInterpolationCRS().orElse(null), 
getInterpolationCRS(that), mode))
                  {
+                     /*
+                      * If one of the operation is a defining conversion, i.e. 
a conversion where the transform
+                      * has not yet been computed, while the other operation 
is a fully-defined conversion, then
+                      * we need to complete the defining operation before we 
can compare the transforms.
+                      */
+                     if (that instanceof AbstractCoordinateOperation) {
+                         that = ((AbstractCoordinateOperation) 
that).comparableTo(this);
+                     }
+                     final CoordinateOperation self = comparableTo(that);
                      /*
                       * At this point all metadata match or can be ignored. 
First, compare the targetCRS.
                       * We need to perform this comparison only if this 
`equals(…)` method is not invoked
diff --cc 
endorsed/src/org.apache.sis.storage.sql/test/org/apache/sis/storage/sql/feature/SelectionClauseWriterTest.java
index dc95a0c3ed,c2228a056e..9c04033749
--- 
a/endorsed/src/org.apache.sis.storage.sql/test/org/apache/sis/storage/sql/feature/SelectionClauseWriterTest.java
+++ 
b/endorsed/src/org.apache.sis.storage.sql/test/org/apache/sis/storage/sql/feature/SelectionClauseWriterTest.java
@@@ -112,11 -155,11 +153,11 @@@ public final class SelectionClauseWrite
       * This method add a CRS on a property for testing purpose.
       */
      @Override
 -    public FeatureType editFeatureType(final TableReference table, final 
FeatureTypeBuilder feature) {
 +    public DefaultFeatureType editFeatureType(final TableReference table, 
final FeatureTypeBuilder feature) {
-         assertEquals("",     table.catalog);
-         assertEquals("APP",  table.schema);
+         assertEquals(expectedCatalog, table.catalog);
+         assertEquals(expectedSchema,  table.schema);
          assertEquals("TEST", table.table);
-         ((AttributeTypeBuilder<?>) 
feature.getProperty("BETA")).setCRS(HardCodedCRS.WGS84);
+         assertInstanceOf(AttributeTypeBuilder.class, 
feature.getProperty("BETA")).setCRS(HardCodedCRS.WGS84);
          return feature.build();
      }
  
diff --cc 
endorsed/src/org.apache.sis.storage/test/org/apache/sis/storage/esri/AsciiGridStoreTest.java
index 493d04b93f,a41fb4c69f..08f53f5698
--- 
a/endorsed/src/org.apache.sis.storage/test/org/apache/sis/storage/esri/AsciiGridStoreTest.java
+++ 
b/endorsed/src/org.apache.sis.storage/test/org/apache/sis/storage/esri/AsciiGridStoreTest.java
@@@ -93,11 -94,11 +93,11 @@@ public final class AsciiGridStoreTest e
              final Metadata metadata = store.getMetadata();
              /*
               * Format information is hard-coded in "SpatialMetadata" 
database. Complete string should
-              * be "ESRI ArcInfo ASCII Grid format" but it depends on the 
presence of Derby dependency.
+              * be "ESRI ArcInfo ASCII Grid format" but it depends on the 
presence of metadata database.
               */
 -            final Identification id = 
assertSingleton(metadata.getIdentificationInfo());
 -            final String format = assertSingletonResourceFormat(id);
 -            assertTrue(format.contains("ASCII Grid"), format);
 +            final DataIdentification id = assertInstanceOf(
 +                    DataIdentification.class,
 +                    assertSingleton(metadata.getIdentificationInfo()));
              /*
               * This information should have been read from the PRJ file.
               */

Reply via email to