hikaricp

Defining an alternate connection pool in Grails 2.3.6

落花浮王杯 提交于 2019-12-19 02:42:13
问题 I know that, at some point between Grails 1.X and Grails 2.X, the default connection pooling library changed from commons-dbcp to tomcat-dbcp . Now, I'm trying to configure either BoneCP or HikariCP as the connection pooling library for my Grails application. However, I see that this answer offers a solution which might only apply to Grails 1.X. I also found this Gist, but again, I don't know which Grails version it applies to. So, is it possible to define a custom connection pool inside a

HikariCP Postgresql Driver Claims to not accept JDBC URL

吃可爱长大的小学妹 提交于 2019-12-18 14:08:12
问题 I've pushed my application to cloudfoundry. However every time I connect to my postgresql/elephant sql I received this error Driver org.postgresql.Driver claims to not accept JDBC URL jdbc:postgres://cwkqmdql:SsVqwdLxQObgaJAYu68O-8gTY1VmS9LX@pellefant.db.elephantsql.com:5432/cwkqmdql/ Is there anything I've missed? 回答1: There are a few issues with that URL and a latest PSQL driver may complain. jdbc:postgres: should be replaced with jdbc:postgresql: Do not use jdbc:postgresql://<username>:

How to configure datasource with HikariCP in Spring @Configuration class?

我与影子孤独终老i 提交于 2019-12-18 11:50:32
问题 I'm trying to configure HikariCP datasource in Spring @Configuration class[Database being oracle]. But it's not working. I searched in the internet and found that HikariCP datasource needs to be configured with constructor. I have tried this [the way it's mentioned in their github webpage], but it still not working. Please help me in solving this problem. private HikariDataSource dataSource() { final HikariDataSource ds = new HikariDataSource(); ds.setMaximumPoolSize(100); ds

How do I configure HikariCP in my Spring Boot app in my application.properties files?

為{幸葍}努か 提交于 2019-12-17 02:42:23
问题 I'm trying to set up HikariCP in my Spring Boot (1.2.0.M1) app so I can test using it in place of Tomcat DBCP. I'd like to configure the connection pool in my application.properties file like I was doing with Tomcat, but I can't figure out how I should be doing it. All examples I've found show either JavaConfig style, or using a separate HikariCP properties file. Can someone help me figure out the property names to configure it in application.properties? I'd like to also switch from using the

How can I get an oracle.jdbc.OracleConnection when using hikari

我与影子孤独终老i 提交于 2019-12-14 00:34:45
问题 I need an oracle.jdbc.OracleConnection to directly work with ORACLE's SDO_GEOMETRY. I have an Object that is of type: class com.zaxxer.hikari.proxy.ConnectionJavassistProxy My debugger says its value is: ConnectionJavassistProxy(1082639682) wrapping oracle.jdbc.driver.T4CConnection@220c1ab2 Note that T4CConnection implements oracle.jdbc.OracleConnection So if I can get access to it, I will have what I need. 回答1: OracleConnection oracleConnection = connection.unwrap(OracleConnection.class); 来源

Cannot create JDBC driver of class '' for connect URL 'null" - HikariCP, Tomcat8, PostgreSQL

一世执手 提交于 2019-12-13 20:52:53
问题 Firstly I have never setup a JDBC Pool before (So i am sorry if this seems mundane). I have been trying for some time to solve the problem but to no avail. I have explored the suggested options from various other stackoverflow posts but none have been successful. I have tried: Including the 'pgjdbc-ng' driver only in the /lib of tomcat and moving the context to the catalina home conf/ Swapping to using the example given by Hikari (but received same error) https://github.com/brettwooldridge

Spring Boot 1.3.5 with Hikari Connection Pool not able to set program name in v$session

我们两清 提交于 2019-12-13 16:45:50
问题 I have a JHipster spring boot ver 1.3.5 application which connects to Oracle DB using Hikari Connection Pool. I am unable to set the program in v$session which should be possible by adding below in my application YAML hikari: v$session: program: AppName username: DB_USER I have tried adding these at spring.datasource level, datasource.hikari level and datasource level. I also looked at Hibernate 4.3.5 ignores v$session.program configuration property but that did not work as well. Update 1 - I

HikariCP connection error

╄→гoц情女王★ 提交于 2019-12-13 09:00:00
问题 Im trying to use HikariCP with a mariaDB database but i getting the next error when im trying to initialize. The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server. at com.zaxxer.hikari.pool.HikariPool.initializeConnections(HikariPool.java:581) ~[Dubilets-1.0-SNAPSHOT.jar:?] at com.zaxxer.hikari.pool.HikariPool.<init>(HikariPool.java:152) ~[Dubilets-1.0-SNAPSHOT.jar:?] at com.zaxxer.hikari.HikariDataSource.<init>

how to utilize HikariCP with Hibernate?

只谈情不闲聊 提交于 2019-12-13 07:36:13
问题 When I used Hibernate itself, I could've done something like Main.getSession().get(User.class, 1); where getSession() would call openSession() from the session factory. but how can I do the same with HikariDataSource ? Wiki mentioned something about HikariConnectionProvider but no example was given. @Bean public DataSource dataSource() throws SQLException { if (dbUrl == null || dbUrl.isEmpty()) { return new HikariDataSource(); } else { HikariConfig config = new HikariConfig(); config

Why are the insert batch times increasing?

我们两清 提交于 2019-12-13 07:13:42
问题 Summary: Inserting 100k rows at a time with 1k batches (yes it's definitely being batched) and time to insert is increasing for each batch. Trying to understand why. Original Question: JProfiler shows a lot of time spent reading an InputStream in ReadAheadInputStream.fill. Update: Per comment below from EJP "The time is being spent blocked in read(), while the database server is executing the statement and preparing the response" What could cause so much time to be spent here? Details: