Skip to content

Commit 5670e4e

Browse files
authored
Merge pull request #73 from pndaproject/PNDA-4504
Remove old code that automatically selected the main jar
2 parents c68b6f9 + 5c4a0c0 commit 5670e4e

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

api/src/main/resources/plugins/sparkStreaming.py

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -137,19 +137,12 @@ def create_component(self, staged_component_path, application_name, user_name, c
137137
['sudo mkdir -p %s' % remote_component_install_path,
138138
'sudo mv %s %s' % (remote_component_tmp_path + '/log4j.properties', remote_component_install_path + '/log4j.properties')])
139139

140-
if 'component_main_py' in properties:
141-
main_jar_name = None
142-
if 'component_main_jar' in properties:
143-
main_jar_name = properties['component_main_jar']
144-
else:
145-
main_jar_name = '*.jar'
146-
147140
commands = []
148141
commands.append('sudo cp %s/%s %s' % (remote_component_tmp_path, service_script, service_script_install_path))
149142
commands.append('sudo cp %s/* %s' % (remote_component_tmp_path, remote_component_install_path))
150143
commands.append('sudo chmod a+x %s/yarn-kill.py' % (remote_component_install_path))
151-
if main_jar_name is not None:
152-
commands.append('cd %s && sudo jar uf %s application.properties' % (remote_component_install_path, main_jar_name))
144+
if 'component_main_jar' in properties:
145+
commands.append('cd %s && sudo jar uf %s application.properties' % (remote_component_install_path, properties['component_main_jar']))
153146
commands.append('sudo rm -rf %s' % (remote_component_tmp_path))
154147
deployer_utils.exec_ssh(target_host, root_user, key_file, commands)
155148

0 commit comments

Comments
 (0)