The MariaDB JDBC driver is downloaded by Java buildpack according to the
detection criterion described in buildpack documentation according to VCAP_SERVICES palyload for the app binding to database service provisioned by CSB for AWS. For example,
$ cf env app1
Getting env variables for app test in org unify / space test as admin...
System-Provided:
VCAP_SERVICES: {
"csb-aws-mysql": [
{
"binding_guid": "e84d3755-4d1a-470d-9526-cf9673949cc9",
"binding_name": null,
"credentials": {
"credhub-ref": "/c/csb/csb-aws-mysql/e84d3755-4d1a-470d-9526-cf9673949cc9/secrets-and-services"
},
"instance_guid": "1ee98d8d-90fb-4524-b5f6-96340344becd",
"instance_name": "unify-dashboard-data-csbunify-it3",
"label": "csb-aws-mysql",
"name": "unify-dashboard-data-csbunify-it3",
"plan": "unifymicro-rds-mysql",
"provider": null,
"syslog_drain_url": null,
"tags": [
"aws",
"mysql"
],
"volume_mounts": []
}
],
......
Although the app already includes its own JDBC driver called aws-mysql-jdbc.jar, but the driver archive name doesn't match exception list as shown
here. That's why MariaDB JDBC driver is still downloaded by Java buildpack.
A Github
issue has been created to request adding driver file aws-mysql-jdbc.jar to the exception list. Before the Github issue is fixed in a new Java buildpack release, user can try to avoid auto downloading MariaDB JDBC driver by renaming self-provided JDBC driver to something like mysql-connector-j*.jar.