Skip to content
This repository has been archived by the owner on Aug 29, 2018. It is now read-only.

Commit

Permalink
Revert "Bug 1169306: Clean up standalone db gear http conf in watchman."
Browse files Browse the repository at this point in the history
  • Loading branch information
maxamillion committed Dec 9, 2014
1 parent f93f483 commit 8432fe8
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions node-util/conf/watchman/plugins.d/frontend_plugin.rb
Original file line number Diff line number Diff line change
Expand Up @@ -67,22 +67,6 @@ def apply(iteration)
FileUtils.rm_r(gear_dir)
end

# Cleanup the empty conf gear directories. For e.g. directories for scalable
# application's db gears.
Dir.glob(PathUtils.join(conf_dir, '*')).each do |entry|
next unless File.directory?(entry)
next unless Dir["#{entry}/*"].empty?

# Verify name is of the form we expect for these directories i.e. gearuuid_domain_gearuuid
dir_name = File.basename(entry)
next if /(.*)_(.*)_(.*)/ !~ dir_name
dir_name_parts = dir_name.split('_')
next if dir_name_parts[0] != dir_name_parts[2]

FileUtils.rm_r(entry)
@logger.info %Q(watchman frontend plugin cleaned up #{entry})
end

if reload_needed
::OpenShift::Runtime::Frontend::Http::Plugins::reload_httpd
end
Expand Down

0 comments on commit 8432fe8

Please sign in to comment.