robertwb commented on a change in pull request #15857:
URL: https://github.com/apache/beam/pull/15857#discussion_r745211708
##########
File path: sdks/python/apache_beam/utils/subprocess_server.py
##########
@@ -158,9 +158,14 @@ class JavaJarServer(SubprocessServer):
'local', (threading.local, ),
dict(__init__=lambda self: setattr(self, 'replacements', {})))()
- def __init__(self, stub_class, path_to_jar, java_arguments):
+ def __init__(self, stub_class, path_to_jar, java_arguments, classpath=None):
+ if classpath:
+ cp_args = ['-classpath', os.pathsep.join(classpath)]
+ else:
+ cp_args = []
super().__init__(
- stub_class, ['java', '-jar', path_to_jar] + list(java_arguments))
+ stub_class,
+ ['java'] + cp_args + ['-jar', path_to_jar] + list(java_arguments))
Review comment:
OK, I added support for this. I was tempted to just drop the classpath
thing, but then the default JavaExternalTransform would be much less useful,
and I think this'll be needed for the JDBC transforms as well.
--
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]