damccorm commented on code in PR #24827: URL: https://github.com/apache/beam/pull/24827#discussion_r1059162781
########## sdks/typescript/build.gradle: ########## @@ -0,0 +1,67 @@ +/* + * 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. + */ + +plugins { id 'org.apache.beam.module' } + +description = "Apache Beam :: SDKs :: Typescript" + +configurations { + packTarball +} + +def tarballName = "apache-beam.tgz" + +def typescriptSdkDeps = project.files( + project.fileTree( + dir: "${project.rootDir}", + include: ['model/**', 'sdks/typescript/src/**', 'sdks/typescript/*.json'], + // Exclude temporary directories and files that are generated + // during build and test. + exclude: [ + '**/build/**', + '**/dist/**', + '**/target/**', + '**/.gogradle/**', + '**/reports/test/index.html', + ]) + ) + +def pack = tasks.register("pack") { + + doLast { + // Build artifact + exec { + executable 'sh' + args '-c', "npm run build && npm pack --pack-destination ${buildDir}" Review Comment: Do we need an `npm install` here? ########## sdks/typescript/container/boot.go: ########## @@ -169,13 +169,14 @@ func main() { args = append(args, "--status_endpoint="+info.GetStatusEndpoint().GetUrl()) } - workerIds := append([]string{*workerId}, info.GetSiblingWorkerIds()...) + workerIds := append([]string{*id}, info.GetSiblingWorkerIds()...) var wg sync.WaitGroup wg.Add(len(workerIds)) for _, workerId := range workerIds { go func(workerId string) { - log.Printf("Executing: python %v", strings.Join(args, " ")) - log.Fatalf("User program exited: %v", execx.ExecuteEnv(map[string]string{"WORKER_ID": workerId}, "npx", args...)) + workerArgs := append(append([]string{}, args...), "--id=" + workerId) Review Comment: Looks like this file might need a `go fmt` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
