title: Driver:com.mysql.jdbc.Driver@75b3ef1a returned null for URL:jdbc for grails app on app engine
body: <p>Followed the steps described here to connect my grails 3.2.9 app to google cloud-sql instance on google-app-engine flexible env</p>
  
  <p><a href="http://guides.grails.org/grails-google-cloud/guide/index.html#deployingTheApp" rel="nofollow noreferrer">http://guides.grails.org/grails-google-cloud/guide/index.html#deployingTheApp</a></p>
  
  <p>My grails version is as follows</p>
  
  <p>==> grails -version
  | Grails Version: 3.2.9
  | Groovy Version: 2.4.10
  | JVM Version: 1.8.0_131</p>
  
  <p>My application.yml looks as follows </p>
  
  <pre><code># tag::dataSourceConfiguration[]
  dataSource:
      pooled: true
      jmxExport: true
      dialect: org.hibernate.dialect.MySQL5InnoDBDialect
  environments:
      development:
          dataSource:
              dbCreate: create-drop
              url: jdbc:h2:mem:devDb;MVCC=TRUE;LOCK_TIMEOUT=10000;DB_CLOSE_ON_EXIT=FALSE
      test:
          dataSource:
              dbCreate: update
              url: jdbc:h2:mem:testDb;MVCC=TRUE;LOCK_TIMEOUT=10000;DB_CLOSE_ON_EXIT=FALSE
      production:
          dataSource:
              driverClassName: com.mysql.jdbc.Driver
              dbCreate: create-drop
              url: jdbc:cloudsql://google/{DATABASE_NAME}?cloudSqlInstance={INSTANCE_NAME}&amp;socketFactory=com.google.cloud.sql.mysql.SocketFactory&amp;user={USERNAME}&amp;password={PASSWORD}&amp;useSSL=false
              properties:
  </code></pre>
  
  <p>When I run locally using</p>
  
  <p>grails run-app </p>
  
  <p>the app runs correctly</p>
  
  <p>I run 
  ./gradlew appengineDeploy to deploy and it deploys correctly</p>
  
  <p>But when I try to open the scaffolded pages in the browser, I see the following error in the logs </p>
  
  <p>==> gcloud app logs tail -s default</p>
  
  <pre><code>    ERROR --- [           main] o.h.engine.jdbc.spi.SqlExceptionHelper 
  
    : Driver:com.mysql.jdbc.Driver@75b3ef1a returned null for 
  
  URL:jdbc:cloudsql://google/{DATABASE_NAME}?cloudSqlInstance=
  
  {INSTANCE_NAME}&amp;socketFactory=com.google.cloud.sql.mysql.SocketFactory&amp;us
  er={USERNAME}&amp;password={PASSWORD}&amp;useSSL=false
  </code></pre>
  
  <p>In addition the following error is also seen in the logs</p>
  
  <pre><code>    ERROR --- [ Thread-16] .SchemaDropperImpl$DelayedDropActionImpl :
  
   HHH000478: Unsuccessful: alter table property drop foreign key 
  
  FKgcduyfiunk1ewg7920pw4l3o9
  </code></pre>
  
  <p>Does the HH indicate that it is using the h2 database in production env?</p>
  
  <p>Please help debug.</p>