mysqldumpをJavaから実行する

String executeCmd = "/path/to/mysql/bin/mysqldump -h{yourhostname} -u"
        + "root " + " --add-drop-database -B " + orgId +" -r /path/to/dump/backup.sql";
Process runtimeProcess;
try {
    runtimeProcess = Runtime.getRuntime().exec(executeCmd);
    int processComplete = runtimeProcess.waitFor();
    if (processComplete == 0) {
        System.out.println("OK");
    } else {
        System.out.println("NG");
    }
} catch (Exception ex) {
    ex.printStackTrace();
}