quarkus: Broken encoding of data retrieved from MS SQL via reactive hibernate
Describe the bug
If data was put into a mssql database via direct sql query(e.g. by using vertx pool or file in quarkus.hibernate-orm.sql-load-script system property) and was retrieved via hibernate reactive session, then all non-ASCII symbols in it will be replaced by either corresponding ASCII symbols(“Č”->“C”) or with some garbage.
Expected behavior
Any data should be retrieved the same as it was put in the database
Actual behavior
Data gets corrupted
How to Reproduce?
Reproducer: https://github.com/fedinskiy/quarkus
, branch reproducer/mssql-encoding
How to run: mvn clean verify -pl io.quarkus:quarkus-integration-test-hibernate-reactive-mssql -Dtest-containers -Dstart-containers
File HibernateReactiveMsSQLTest contains several tests:
vertxQuery — data is put to the database via MSSQLPool.query and retrieved via Mutiny.Session.find. Fails
vertxRetrieval — data is put to and retrieved from the database via MSSQLPool.query. Fails
persisted — data is put to the database via Mutiny.Session.persist and retrieved via Mutiny.Session.find. Succeeds
imported — data is put to the database via quarkus.hibernate-orm.sql-load-script
Quarkus property and retrieved via Mutiny.Session.find. Fails
jdbc — data is put to the database via quarkus.hibernate-orm.sql-load-script
Quarkus property and retrieved via jdbc. Succeeds
sanity — send data over the network without accessing the DB
Output of uname -a
or ver
5.13.8-200.fc34.x86_64
Output of java -version
11.0.11
GraalVM version (if different from Java)
No response
Quarkus version or git rev
d67f466512f15901a78f0a63e36560b1830b24ff
Build tool (ie. output of mvnw --version
or gradlew --version
)
3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
Additional information
No response
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 18 (11 by maintainers)
@gavinking I think that’s what you meant? Isn’t it?