Repository: beam
Updated Branches:
  refs/heads/master 6cef5c7b6 -> af69e979a


[BEAM-2745] Add Jenkins Suite for Python Performance Test


Project: http://git-wip-us.apache.org/repos/asf/beam/repo
Commit: http://git-wip-us.apache.org/repos/asf/beam/commit/fd8f15f1
Tree: http://git-wip-us.apache.org/repos/asf/beam/tree/fd8f15f1
Diff: http://git-wip-us.apache.org/repos/asf/beam/diff/fd8f15f1

Branch: refs/heads/master
Commit: fd8f15f1ac761425dc791a455b042a8846081f48
Parents: 6cef5c7
Author: Mark Liu <mark...@google.com>
Authored: Thu Jun 22 14:04:00 2017 -0700
Committer: Ahmet Altay <al...@google.com>
Committed: Fri Jun 23 14:03:14 2017 -0700

----------------------------------------------------------------------
 .../jenkins/common_job_properties.groovy        |  4 +-
 .../job_beam_PerformanceTests_Python.groovy     | 58 ++++++++++++++++++++
 2 files changed, 61 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/beam/blob/fd8f15f1/.test-infra/jenkins/common_job_properties.groovy
----------------------------------------------------------------------
diff --git a/.test-infra/jenkins/common_job_properties.groovy 
b/.test-infra/jenkins/common_job_properties.groovy
index 6d4d68b..0e047ea 100644
--- a/.test-infra/jenkins/common_job_properties.groovy
+++ b/.test-infra/jenkins/common_job_properties.groovy
@@ -264,8 +264,10 @@ class common_job_properties {
         shell('rm -rf PerfKitBenchmarker')
         // Clone appropriate perfkit branch
         shell('git clone 
https://github.com/GoogleCloudPlatform/PerfKitBenchmarker.git')
-        // Install job requirements.
+        // Install Perfkit benchmark requirements.
         shell('pip install --user -r PerfKitBenchmarker/requirements.txt')
+        // Install job requirements for Python SDK.
+        shell('pip install --user -e sdks/python/[gcp,test]')
         // Launch performance test.
         shell("python PerfKitBenchmarker/pkb.py $pkbArgs")
     }

http://git-wip-us.apache.org/repos/asf/beam/blob/fd8f15f1/.test-infra/jenkins/job_beam_PerformanceTests_Python.groovy
----------------------------------------------------------------------
diff --git a/.test-infra/jenkins/job_beam_PerformanceTests_Python.groovy 
b/.test-infra/jenkins/job_beam_PerformanceTests_Python.groovy
new file mode 100644
index 0000000..6a71bda
--- /dev/null
+++ b/.test-infra/jenkins/job_beam_PerformanceTests_Python.groovy
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import common_job_properties
+
+// This job runs the Beam Python performance tests on PerfKit Benchmarker.
+job('beam_PerformanceTests_Python'){
+  // Set default Beam job properties.
+  common_job_properties.setTopLevelMainJobProperties(delegate)
+
+  // Run job in postcommit every 6 hours, don't trigger every push.
+  common_job_properties.setPostCommit(
+      delegate,
+      '0 */6 * * *',
+      false,
+      'commits@beam.apache.org')
+
+  // Allows triggering this build against pull requests.
+  common_job_properties.enablePhraseTriggeringFromPullRequest(
+      delegate,
+      'Python SDK Performance Test',
+      'Run Python Performance Test')
+
+  def pipelineArgs = [
+      project: 'apache-beam-testing',
+      staging_location: 'gs://temp-storage-for-end-to-end-tests/staging-it',
+      temp_location: 'gs://temp-storage-for-end-to-end-tests/temp-it',
+      output: 'gs://temp-storage-for-end-to-end-tests/py-it-cloud/output'
+  ]
+  def pipelineArgList = []
+  pipelineArgs.each({
+    key, value -> pipelineArgList.add("--$key=$value")
+  })
+  def pipelineArgsJoined = pipelineArgList.join(',')
+
+  def argMap = [
+      beam_sdk : 'python',
+      benchmarks: 'beam_integration_benchmark',
+      beam_it_args: pipelineArgsJoined
+  ]
+
+  common_job_properties.buildPerformanceTest(delegate, argMap)
+}

Reply via email to