in lib/app/console_app.rb [63:83]
def register_connector
if connector_id.present?
puts "You already have registered a connector with ID: #{connector_id}. Registering a new connector will overwrite the existing one."
puts 'Are you sure you want to continue? (y/N)'
return false unless gets.chomp.strip.casecmp('y').zero?
end
puts 'Please enter index name for data ingestion. Use only letters, underscored and dashes.'
index_name = gets.chomp.strip
unless INDEX_NAME_REGEXP.match?(index_name)
puts "Index name #{index_name} contains symbols that aren't allowed!"
return false
end
puts 'Do you want to use ICU Analysis Plugin? (y/N)'
use_analysis_icu = gets.chomp.strip.casecmp('y').zero?
language_code = select_analyzer
created_id = create_connector(index_name, use_analysis_icu, language_code)
update_connector_id(created_id)
true
end