Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8532423
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T09:42:44+00:00 2026-06-11T09:42:44+00:00

I try to make a simple test with spring/jpa/hibernate and GAE/Google Cloud SQL. But

  • 0

I try to make a simple test with spring/jpa/hibernate and GAE/Google Cloud SQL.

But I can’t find the right configuration and I always keep getting :

Caused by: com.google.apphosting.api.ApiProxy$CallNotFoundException: The API package 'rdbms' or call 'OpenConnection()' was not found.
    at com.google.apphosting.api.ApiProxy.makeSyncCall(ApiProxy.java:98) ~[appengine-api-1.0-sdk-1.6.4.1.jar:na]
    at com.google.appengine.api.rdbms.RdbmsApiProxyClient$ApiProxyBlockingInterface.makeSyncCall(RdbmsApiProxyClient.java:95) ~[appengine-api-1.0-sdk-1.6.4.1.jar:na]
    at com.google.appengine.api.rdbms.RdbmsApiProxyClient$ApiProxyBlockingInterface.openConnection(RdbmsApiProxyClient.java:73) ~[appengine-api-1.0-sdk-1.6.4.1.jar:na]
    at com.google.cloud.sql.jdbc.internal.SqlProtoClient.openConnection(SqlProtoClient.java:58) ~[appengine-api-1.0-sdk-1.6.4.1.jar:na]
    at com.google.cloud.sql.jdbc.Driver.connect(Driver.java:66) ~[appengine-api-1.0-sdk-1.6.4.1.jar:na]
    at com.google.cloud.sql.jdbc.Driver.connect(Driver.java:26) ~[appengine-api-1.0-sdk-1.6.4.1.jar:na]
    at java.sql.DriverManager.getConnection(DriverManager.java:579) ~[na:1.7.0]
    at java.sql.DriverManager.getConnection(DriverManager.java:190) ~[na:1.7.0]
    at org.hibernate.service.jdbc.connections.internal.DriverManagerConnectionProviderImpl.getConnection(DriverManagerConnectionProviderImpl.java:192) ~[hibernate-core-4.1.2.Final.jar:4.1.2.Final]

versions :

  • Spring framework : 3.1.1
  • Hibernate : 4.1.2
  • Google App Engine : 1.6.4.1

persistence.xml :

<persistence xmlns="http://java.sun.com/xml/ns/persistence"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
      http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
    version="2.0">

    <persistence-unit name="gae-test" transaction-type="RESOURCE_LOCAL">
        <provider>org.hibernate.ejb.HibernatePersistence</provider>
        <class>com.gro.gae.domainmodel.user.UserEntity</class>
        <properties>
            <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"></property>
            <property name="hibernate.show_sql" value="true"></property>
            <property name="hibernate.hbm2ddl.auto" value="update"></property>
            <property name="hibernate.connection.url" value="jdbc:google:rdbms://sqlpetstocks:petstocks/dngdatabase"></property>
            <property name="hibernate.connection.driver_class" value="com.google.appengine.api.rdbms.AppEngineDriver"></property>
            <property name="hibernate.connection.driver_class" value="com.google.cloud.sql.Driver"></property>
        </properties>
    </persistence-unit>

</persistence>

applicationContext.xml

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:jpa="http://www.springframework.org/schema/data/jpa"
    xmlns:context="http://www.springframework.org/schema/context" xmlns:tx="http://www.springframework.org/schema/tx"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
    http://www.springframework.org/schema/data/jpa http://www.springframework.org/schema/data/jpa/spring-jpa.xsd
    http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
    http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd">

    <jpa:repositories base-package="com.gro.gae.persistence"
        factory-class="com.gro.gae.persistence.CustomJpaRepositoryFactoryBean" />

    <bean id="entityManagerFactory" class="org.springframework.orm.jpa.LocalEntityManagerFactoryBean">
        <property name="persistenceUnitName" value="gae-test" /> 
    </bean>

    <bean name="transactionManager" class="org.springframework.orm.jpa.JpaTransactionManager">
        <property name="entityManagerFactory" ref="entityManagerFactory" />
    </bean>

    <context:annotation-config />

    <tx:annotation-driven />

</beans>

unit test :

@RunWith(org.springframework.test.context.junit4.SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = { "classpath:applicationContext-persistence.xml" })
@TestExecutionListeners( { DependencyInjectionTestExecutionListener.class, TransactionalTestExecutionListener.class })
@TransactionConfiguration(defaultRollback = true)
@Transactional
public class ConfigurationTest  {

    @Test
    public void testConfig(){

    }

}

Any ideas ?

Thanks

Guillaume

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T09:42:45+00:00Added an answer on June 11, 2026 at 9:42 am

    Too late but maybe it’ll help someone.
    I found the same problem and the VM args didn’t work under JUnit execution.

    The solution was for me to define another entityManager/persistenceUnit for tests.

    The key was to change in the new testPersistence.xml the properties:

    <property name="javax.persistence.jdbc.driver" value="com.google.appengine.api.rdbms.AppEngineDriver"/>
    <property name="javax.persistence.jdbc.url" value="jdbc:google:rdbms:localhost:3306/DB_NAME" />
    

    with

    <property name="javax.persistence.jdbc.driver" value="com.mysql.jdbc.Driver" />
    <property name="javax.persistence.jdbc.url" value="jdbc:mysql://localhost:3306/DB_NAME" />
    

    Hope this helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm pretty new to PHP, but I decided to try and make a simple
I'll try to make this as simple as possible. I'm working on a site
Alright, I'll try and make this as simple as possible. I'm trying to create
I wanted to make some simple file recovery software, where I want to try
Ok, so I'll try to make that question a little more simple. The core
New to batch files, first try actually. Trying to make a simple batch file
A seemingly simple one here. How can I test the exception handling of this
I'm trying to make some simple XML with Java and org.w3c.dom, but I got
I try to make my ListBox connected to ObservaleCollection be more efficient so for
I try to make an ActiveX by C# with COM-visible. It is a Windows

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.