We are using JBoss 4.0.3 SP1 using Hypersonic as its internal storage engine (timers, queues, etc.)
The database is no longer accessible (most likely data corruption) giving error; Caused by: org.hsqldb.HsqlException: old version database must be shutdown.
Is there a way or command to shutdown the database to recover the data (~150MB) stuck in the flat file?
Edit
Resolved the connection problem by downgrading to Hypersonic 1.8. How ever the database itself is corrupt. You have rows with duplicate keys, and lots of null fields. Having read this article and this one, i'm in the process of changing the default JBossMQ database to MS SQL
According to the hsql documentation the command is SHUTDOWN. As far as I remember, hsql saves the data as a set of sql queries, so you need to have a look on the file.
Notice that according to JBoss,
Hypersonic(HSQLDB) SHOULD NOT be used
in production at all. It is not
suitable for production use.
Related
We have a Java application (basically integration tests) that uses Hibernate (which uses Jdbc) to read/write data to the MySQL Database. Hibernate objects like sessions or transactions are created and configured via our own code (no Spring or other wrappers are being used). The issue is that periodically (multiple times during tests execution) we observe a "No database selected" exception. Database URL that we use for DataSource configuration already contains database name in it:
jdbc:mysql://localhost:3306/test?useSSL=false&createDatabaseIfNotExist=false&cacheServerConfiguration=true&cacheResultSetMetadata=true&useLocalSessionState=true&rewriteBatchedStatements=true&tcpNoDelay=true&tcpTrafficClass=16&alwaysSendSetIsolation=false&tcpSndBuf=1048576&tcpRcvBuf=1048576&characterEncoding=utf8&allowPublicKeyRetrieval=true
I tried to catch the Exception and test the connection's selected database by running select database() and it actually reports that the value is null on the database side.
Even more strange thing is that next queries on the same connection are executed against the normal database (so it somehow self-heals).
Does anybody know why can MySQL connections "lose" and then "restore" selected database?
Or maybe there is a way to trace the problem down. Will be grateful for any help or thought that you can provide
Versions:
Java 1.8.0_292
Mysql 5.6.31
Hibernate 5.4.2
JDBC mysql-connector-java 8.0.22
I'm really looking for and advice on how to set up data streaming between Oracle db (just for example) and Clickhouse database using Airbyte ETL tool.
I've created the source and destination connectors and successfuly tested the connections but now I'm facing the issue in syncing the data. While the source is sending the data correctly, the destination (Clickhouse) JDBC driver requires the schema to accept those tables.
So, I don't know how to retrieve this schema and where it should be stored. Maybe there're some means to create this schema, because when I inspect the log it displays such thing:
So, basically, the error is connected with Exception in thread "main" java.lang.IllegalStateException: jdbc destinations must specify a schema.
Please I will be really grateful for providing any means for resolving that issue!
I think use should try version 0.1.1 of ClickHouse destination. It fixes your issue https://github.com/airbytehq/airbyte/pull/8982
Running spring-boot 2.1.3.RELEASE and using liquibase 3.6.3 on Oracle 12.1.0.2.v15, I get exception on startup:
Did not update change log lock correctly.\n\n 0 rows were updated instead of the expected 1 row using executor oracle there are 0 rows in the table
This:
https://github.com/liquibase/liquibase/blob/master/liquibase-core/src/main/java/liquibase/lockservice/StandardLockService.java#L334
Investigating, I suspect it might be related to some missing right of my user as it works fine on a database created with AWS RDS 12.1.0.2.v15 but not on the on premise database.
The only noticeable difference is that the user for on premise has no access to v$parameter so I get:
Could not set check compatibility mode on OracleDatabase, assuming not running in any sort of compatibility mode: Cannot read from v$parameter: ..
Has anybody an idea ?
Can it be related to autocommit default value ?
Any link to requirements for Oracle user when using liquibase ?
So the issue ended up being an Oracle user misconfiguration by DBA, he had no privileges on tablespace.
But this issue didn't appear in logs.
Once I removed liquibase context:
spring.liquibase.contexts
The issue appeared clearly:
ORA-01950 : no privileges on tablespace ....
I'm trying to deploy an application to my GlassFish Server environment. I've set it up so that GlassFish creates a connection pool to a postgreSQL database on another server (not localhost) where the database is located. I test the connection and then try to deploy the application. It fails with a java.lang.RuntimeException: EJB Container initialization error, and my error log contains the following: http://ideone.com/UlZXut (put it here due to its size). There were other warnings above these, but they only referred to tables already existing.
As according to this, I thought that the required sun-cmp-mappings.xml file (the one I assume would be necessary for this correct mapping) would be automatically generated upon deployment, but it seems I was wrong. Could anyone shed some light on this situation?
My apologies if this is not the absolute best part of SE to post this, but it is related to development tools and I did see a number of related posts.
Your error log indicates that you are trying to create table(s) with DOUBLE as a datatype. In Postgresql, that datatype is actually called "double precision". What happens if you revise the table definition to use "double precision" instead?
on startup Glassfish tries to create the DB tables for your java code. It fails to do that and it fails to startup.
Check the configuration of your ORM mapper.
I have a struts 2 application and a toplink persistence provider running on tomcat 6.0.20 and a MySql 5.1.38 server on a GNU/Linux machine. After committing the data the when i go to retrieve it the data it has disappeared from the database.
I do a em.commit() and em.flush() after my queries have executed. How do they disappear? I am using all standard configuration files. I have reduced the wait_timeout and the interactive_timout period in mysql. Also am using autoReconnectforPools in my persistence.xml.
I also invalidate the cache on every users logout.
Any ideas?
anyway it does not matter, the problem was solved by removing softweak from persistence.xml's entity type declaration and adding hardweak in its place.