hibernate-tools-maven:6.2.6.Final is unable to convert UUID through reverse engineering

Hi Team,

I am trying to implement Hibernate reverse engineering for entity creation; however, I am encountering an issue where Hibernate is treating UUID as a Serializable object instead of a UUID. Below is my configuration. Could you please assist here?

		<plugin>
			<groupId>org.hibernate.tool</groupId>
			<artifactId>hibernate-tools-maven</artifactId>
			<version>6.2.6.Final</version>
			<dependencies>
				<dependency>
					<groupId>org.postgresql</groupId>
					<artifactId>postgresql</artifactId>
					<version>${postgresql.version}</version>
				</dependency>
				<dependency>
					<groupId>org.hibernate</groupId>
					<artifactId>hibernate-core</artifactId>
					<version>6.2.6.Final</version>
				</dependency>
				<dependency>
					<groupId>org.hibernate.tool</groupId>
					<artifactId>hibernate-tools-orm</artifactId>
					<version>6.2.6.Final</version>
				</dependency>
			</dependencies>
			<executions>
				<execution>
					<id>Display Help</id>
					<phase>validate</phase>
					<goals>
						<goal>help</goal>
					</goals>
				</execution>
				<execution>
					<id>Schema generation</id>
					<phase>generate-resources</phase>
					<goals>
						<goal>hbm2java</goal>
					</goals>
				
				</execution>
			</executions>
			<configuration>
				<outputDirectory>src/main/java</outputDirectory>
				<packageName>com.poc.entity</packageName>
				<detectOneToOne>true</detectOneToOne>
				<detectManyToMany>true</detectManyToMany>
				<createCollectionForForeignKey>true</createCollectionForForeignKey>
				<createManyToOneForForeignKey>true</createManyToOneForForeignKey>
				<ejb3>true</ejb3>
				<jdk5>true</jdk5>
				<revengFile>${project.basedir}/src/main/resources/hibernate.reveng.xml</revengFile>
				<format>true</format>
				<!--<delimiter>;</delimiter>
				<haltOnError>true</haltOnError>-->
			</configuration>
		</plugin>

Hi,

Would it be possible to provide a reproducer application? Especially a database creation script of a DB (preferably H2) that shows the issue?

Cheers,
Koen

Hi Koen_Aers,

I apologize, but I cannot provide a reproducible application at the moment. Below is my DB script that has been executed in PostgreSQL. There are multiple tables, but I am providing a single script for your reference.

CREATE TABLE product.entity (
entity_id uuid NOT NULL,
deleted bool NULL DEFAULT false,
“name” varchar(255) NULL,
location_id uuid NULL,
created_date timestamp NOT NULL,
created_user_id uuid NOT NULL,
updated_date timestamp NULL,
updated_user_id uuid NULL,
encrypted_switch bool NULL
CONSTRAINT entity_pk PRIMARY KEY (entity_id)
);
CREATE INDEX entity_deleted_idx01 ON users_owner.entity USING btree (deleted);