Skip to content

Commit 48c5268

Browse files
committed
Issue #2470293 by skek, JulienF: Incompatible with Qbox clusters - Fixed.
1 parent d446941 commit 48c5268

File tree

2 files changed

+3
-10
lines changed

2 files changed

+3
-10
lines changed

composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"require": {
3-
"elasticsearch/elasticsearch": "~1.0.2"
3+
"elasticsearch/elasticsearch": "~1.0"
44
}
55
}

elasticsearch_connector.admin.inc

+2-9
Original file line numberDiff line numberDiff line change
@@ -323,21 +323,14 @@ function elasticsearch_connector_edit_cluster($form, $form_state, $cluster = NUL
323323
'#type' => 'textfield',
324324
'#title' => t('Server URL'),
325325
'#default_value' => !empty($cluster->url) ? $cluster->url : '',
326-
'#description' => t('Enter the URL of a server (node) in the cluster. Example: http://localhost:9200.'),
326+
'#description' => t('Enter the URL and the port of a server (node) in the cluster. Example: http://localhost:9200. Please enter the port also even it is the default one e.g. https://localhost:443'),
327327
'#required' => TRUE,
328328
//'#limit_validation_errors' => array(array('url')),
329329
);
330330

331331
$cluster_info = NULL;
332332
$form_state_active = FALSE;
333-
if (isset($form_state['values'])) {
334-
$values = (object)$form_state['values'];
335-
if (!empty($values->url)) {
336-
$cluster_info = elasticsearch_connector_get_cluster_info($values);
337-
$form_state_active = TRUE;
338-
}
339-
}
340-
elseif (isset($cluster->url)) {
333+
if (isset($cluster->url) && empty($form_state['input'])) {
341334
$cluster_info = elasticsearch_connector_get_cluster_info($cluster);
342335
$form_state_active = TRUE;
343336
}

0 commit comments

Comments
 (0)