title: Google Dataflow (Apache beam) JdbcIO bulk insert into mysql database
body: <p>I'm using Dataflow SDK 2.X Java API ( Apache Beam SDK) to write data into mysql. I've created pipelines based on <a href="https://beam.apache.org/documentation/sdks/javadoc/0.5.0/org/apache/beam/sdk/io/jdbc/JdbcIO.html" rel="noreferrer">Apache Beam SDK documentation</a> to write data into mysql using dataflow. It inserts single row at a time where as I need to implement bulk insert. I do not find any option in official documentation to enable bulk inset mode. </p>
  
  <p>Wondering, if it's possible to set bulk insert mode in dataflow pipeline? If yes, please let me know what I need to change in below code.</p>
  
  <pre><code> .apply(JdbcIO.&lt;KV&lt;Integer, String&gt;&gt;write()
        .withDataSourceConfiguration(JdbcIO.DataSourceConfiguration.create(
              "com.mysql.jdbc.Driver", "jdbc:mysql://hostname:3306/mydb")
            .withUsername("username")
            .withPassword("password"))
        .withStatement("insert into Person values(?, ?)")
        .withPreparedStatementSetter(new JdbcIO.PreparedStatementSetter&lt;KV&lt;Integer, String&gt;&gt;() {
          public void setParameters(KV&lt;Integer, String&gt; element, PreparedStatement query) {
            query.setInt(1, kv.getKey());
            query.setString(2, kv.getValue());
          }
        })
  </code></pre>