import org.elasticsearch.gradle.precommit.PrecommitTasks apply plugin: 'elasticsearch.esplugin' esplugin { name 'ml' description 'Machine Learning Plugin' classname 'org.elasticsearch.xpack.ml.MlPlugin' } version = project.version thirdPartyAudit.enabled = false configurations { nativeBundle } dependencies { compile group: 'net.sf.supercsv', name: 'super-csv', version:"${supercsvVersion}" nativeBundle group: "${project.group}", name: 'ml-cpp-test', version:"${project.version}", classifier: 'darwin-x86_64', ext: 'zip' nativeBundle group: "${project.group}", name: 'ml-cpp-test', version:"${project.version}", classifier: 'linux-x86_64', ext: 'zip' nativeBundle group: "${project.group}", name: 'ml-cpp-test', version:"${project.version}", classifier: 'windows-x86_64', ext: 'zip' testCompile group: 'org.ini4j', name: 'ini4j', version:"${ini4jVersion}" } test { exclude '**/*NoBootstrapTests.class' } task noBootstrapTest(type: Test, dependsOn: test.dependsOn) { classpath = project.test.classpath testClassesDir = project.test.testClassesDir include '**/*NoBootstrapTests.class' } check.dependsOn noBootstrapTest noBootstrapTest.mustRunAfter test integTest { cluster { //setting 'useNativeProcess', 'true' distribution = 'zip' } } integTest.mustRunAfter noBootstrapTest bundlePlugin { if (project.cppLocalDists) { String localZipFile = 'ml-cpp-${project.version}-' + (project.isWindows ? "windows-x86_64" : (project.isMacOsX ? "darwin-x86_64" : (project.isLinux ? "linux-x86_64" : "sunos-x86_64"))) + ".zip" from { zipTree(cppLocalDists + '/' + localZipFile) } } else { for (outputFile in configurations.nativeBundle) { from(zipTree(outputFile)) { duplicatesStrategy 'exclude' } } } }