Skip to content

Commit ad5661d

Browse files
author
Marius Burkard
committed
- drop mongodb code
1 parent 0868b08 commit ad5661d

File tree

14 files changed

+7
-197
lines changed

14 files changed

+7
-197
lines changed

install/sql/incremental/upd_dev_collection.sql

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,3 +104,8 @@ ALTER TABLE `client`
104104
ALTER TABLE `xmpp_domain`
105105
ADD COLUMN `use_webpresence` enum('n','y') NOT NULL DEFAULT 'y',
106106
ADD COLUMN `use_http_upload` enum('n','y') NOT NULL DEFAULT 'n';
107+
108+
109+
-- STRIPDOWN!
110+
ALTER TABLE `web_backup` CHANGE `backup_type` `backup_type` enum('web','mysql') NOT NULL DEFAULT 'web';
111+
ALTER TABLE `web_database_user` DROP COLUMN `database_password_mongo`;

install/sql/ispconfig3.sql

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1927,7 +1927,7 @@ CREATE TABLE `web_backup` (
19271927
`backup_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
19281928
`server_id` int(10) unsigned NOT NULL DEFAULT '0',
19291929
`parent_domain_id` int(10) unsigned NOT NULL DEFAULT '0',
1930-
`backup_type` enum('web','mysql','mongodb') NOT NULL DEFAULT 'web',
1930+
`backup_type` enum('web','mysql') NOT NULL DEFAULT 'web',
19311931
`backup_mode` varchar(64) NOT NULL DEFAULT '',
19321932
`tstamp` int(10) unsigned NOT NULL DEFAULT '0',
19331933
`filename` varchar(255) NOT NULL DEFAULT '',
@@ -1986,7 +1986,6 @@ CREATE TABLE IF NOT EXISTS `web_database_user` (
19861986
`database_user` varchar(64) DEFAULT NULL,
19871987
`database_user_prefix` varchar(50) NOT NULL default '',
19881988
`database_password` varchar(64) DEFAULT NULL,
1989-
`database_password_mongo` varchar(32) DEFAULT NULL,
19901989
PRIMARY KEY (`database_user_id`)
19911990
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
19921991

interface/lib/classes/tools_monitor.inc.php

Lines changed: 0 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -504,39 +504,6 @@ function showFail2ban() {
504504
return $html;
505505
}
506506

507-
function showMongoDB() {
508-
global $app;
509-
510-
/* fetch the Data from the DB */
511-
$record = $app->db->queryOneRecord("SELECT data, state FROM monitor_data WHERE type = 'log_mongodb' and server_id = ? ORDER BY created DESC", $_SESSION['monitor']['server_id']);
512-
513-
if(isset($record['data'])) {
514-
$html =
515-
'<div class="systemmonitor-state state-'.$record['state'].'">
516-
<div class="systemmonitor-content icons32 ico-'.$record['state'].'">';
517-
518-
/*
519-
* First, we have to detect, if there is any monitoring-data.
520-
* If not (because mongodb is not installed) show this.
521-
*/
522-
$data = unserialize($record['data']);
523-
if ($data == '') {
524-
$html .= '<p>'.
525-
'MongoDB is not installed on this server.<br />' .
526-
'</p>';
527-
}
528-
else {
529-
$html .= nl2br($data);
530-
}
531-
$html .= '</div></div>';
532-
533-
} else {
534-
$html = '<p>There is no data available at the moment.</p>';
535-
}
536-
537-
return $html;
538-
}
539-
540507
function showIPTables() {
541508
global $app;
542509
$record = $app->db->queryOneRecord("SELECT data, state FROM monitor_data WHERE type = 'iptables_rules' and server_id = ? ORDER BY created DESC", $_SESSION['monitor']['server_id']);

interface/web/admin/form/server_config.tform.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1858,12 +1858,6 @@
18581858
'default' => 'n',
18591859
'value' => array(0 => 'n', 1 => 'y')
18601860
),
1861-
'do_not_try_rescue_mongodb' => array(
1862-
'datatype' => 'VARCHAR',
1863-
'formtype' => 'CHECKBOX',
1864-
'default' => 'n',
1865-
'value' => array(0 => 'n', 1 => 'y')
1866-
),
18671861
'do_not_try_rescue_mysql' => array(
18681862
'datatype' => 'VARCHAR',
18691863
'formtype' => 'CHECKBOX',

interface/web/admin/templates/server_config_rescue_edit.htm

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,6 @@ <h1><tmpl_var name="list_head_txt"> {tmpl_var name='server_name'}</h1>
1717
{tmpl_var name='do_not_try_rescue_httpd'}
1818
</div>
1919
</div>
20-
<!--
21-
<div class="form-group">
22-
<label class="col-sm-3 control-label">{tmpl_var name='do_not_try_rescue_mongodb_txt'}</label>
23-
<div class="col-sm-9">
24-
{tmpl_var name='do_not_try_rescue_mongodb'}
25-
</div>
26-
</div>
27-
-->
2820
<div class="form-group">
2921
<label class="col-sm-3 control-label">{tmpl_var name='do_not_try_rescue_mysql_txt'}</label>
3022
<div class="col-sm-9">

interface/web/monitor/lib/module.conf.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -201,12 +201,6 @@
201201
'link' => 'monitor/show_data.php?type=fail2ban',
202202
'html_id' => 'fai2ban');
203203

204-
/*
205-
$items[] = array( 'title' => "Show MongoDB-Log",
206-
'target' => 'content',
207-
'link' => 'monitor/show_data.php?type=mongodb',
208-
'html_id' => 'mongodb');
209-
*/
210204
$items[] = array( 'title' => "Show IPTables",
211205
'target' => 'content',
212206
'link' => 'monitor/show_data.php?type=iptables',

interface/web/monitor/show_data.php

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -138,15 +138,6 @@
138138
$description = '';
139139
$add_padding = true;
140140
break;
141-
/*
142-
case 'mongodb':
143-
$template = 'templates/show_data.htm';
144-
$output .= $app->tools_monitor->showMongoDB();
145-
$time = $app->tools_monitor->getDataTime('log_mongodb');
146-
$title = $app->lng("monitor_title_mongodb_txt") . ' (' . $monTransSrv . ' : ' . $_SESSION['monitor']['server_name'] . ')';
147-
$description = '';
148-
break;
149-
*/
150141
case 'iptables':
151142
$template = 'templates/show_data.htm';
152143
$output .= $app->tools_monitor->showIPTables();

interface/web/sites/database_user_edit.php

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -168,14 +168,6 @@ function onBeforeUpdate() {
168168
$this->dataRecord['database_user'] = substr($dbuser_prefix . $this->dataRecord['database_user'], 0, 16);
169169
}
170170

171-
/* prepare password for MongoDB */
172-
// TODO: this still doens't work as when only the username changes we have no database_password.
173-
// taking the one from oldData doesn't work as it's encrypted...shit!
174-
/*
175-
$this->dataRecord['database_password_mongo'] = $this->dataRecord['database_user'].":mongo:".$this->dataRecord['database_password'];
176-
177-
$this->dataRecord['server_id'] = 0; // we need this on all servers
178-
*/
179171
parent::onBeforeUpdate();
180172
}
181173

@@ -211,9 +203,6 @@ function onBeforeInsert() {
211203

212204
$this->dataRecord['server_id'] = 0; // we need this on all servers
213205

214-
/* prepare password for MongoDB */
215-
// $this->dataRecord['database_password_mongo'] = $this->dataRecord['database_user'].":mongo:".$this->dataRecord['database_password'];
216-
217206
parent::onBeforeInsert();
218207
}
219208

interface/web/sites/form/database.tform.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,6 @@
9090
'formtype' => 'SELECT',
9191
'default' => 'mysql',
9292
'value' => array(
93-
/*'mongo' => 'MongoDB',*/
9493
'mysql' => 'MySQL'
9594
)
9695
),

interface/web/sites/form/database_user.tform.php

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -115,15 +115,7 @@
115115
'value' => '',
116116
'width' => '30',
117117
'maxlength' => '255'
118-
),
119-
'database_password_mongo' => array (
120-
'datatype' => 'VARCHAR',
121-
'formtype' => 'PASSWORD',
122-
'default' => '',
123-
'value' => '',
124-
'width' => '30',
125-
'maxlength' => '255'
126-
),
118+
)
127119
//#################################
128120
// ENDE Datatable fields
129121
//#################################

0 commit comments

Comments
 (0)