MultiGLPi Specifications » History » Version 4

SphynXz, 05/19/2011 12:27 PM

1 1 walid
h1. MultiGLPi Specifications
2 1 walid
3 1 walid
h2. Dependancies
4 1 walid
5 2 walid
This plugin will needs the following softwares to work :
6 1 walid
* GLPI 0.80 and higher
7 1 walid
* WebServices plugin version 1.1.0 and higher
8 1 walid
9 1 walid
h2. Uses cases 
10 1 walid
11 1 walid
* Unidirectionnal synchronization between one central and several local GLPI
12 1 walid
* Bidirectionnal synchronization between or more GLPI
13 1 walid
14 1 walid
h2. Workflow
15 1 walid
16 1 walid
h2. Tables
17 1 walid
18 3 SphynXz
19 3 SphynXz
h3. GLPI items
20 3 SphynXz
21 3 SphynXz
22 3 SphynXz
list of GLPI items to synchronise for each slave server
23 3 SphynXz
24 3 SphynXz
<pre>
25 3 SphynXz
DROP TABLE IF EXISTS `glpi_plugin_multiglpi_items`;
26 4 SphynXz
CREATE TABLE IF NOT EXISTS `glpi_plugin_multiglpi_items` (
27 3 SphynXz
  `id` int(11) NOT NULL auto_increment,
28 3 SphynXz
  `item` varchar(255) collate utf8_unicode_ci default NULL,
29 3 SphynXz
  `type` ENUM('core','plugin') NOT NULL default 'core',
30 3 SphynXz
  `is_active` TINYINT NOT NULL default '0', //Activate or not this slave
31 3 SphynXz
  `multiglpi_servers_id` TINYINT NOT NULL default '1',
32 3 SphynXz
   PRIMARY KEY  (`id`)
33 3 SphynXz
) ENGINE=MyISAM  DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
34 3 SphynXz
</pre>
35 3 SphynXz
36 3 SphynXz
37 3 SphynXz
38 1 walid
h3. Slave GLPI servers
39 1 walid
40 1 walid
<pre>
41 1 walid
DROP TABLE IF EXISTS `glpi_plugin_multiglpi_servers`;
42 1 walid
CREATE TABLE IF NOT EXISTS `glpi_plugin_multiglpi_servers` (
43 1 walid
  `id` int(11) NOT NULL auto_increment,
44 1 walid
  `name` varchar(255) collate utf8_unicode_ci default NULL,
45 1 walid
  `host` varchar(255) collate utf8_unicode_ci default NULL,
46 1 walid
  `url` varchar(255) collate utf8_unicode_ci default NULL,
47 1 walid
  `ws_user` varchar(50) collate utf8_unicode_ci default NULL,
48 1 walid
  `ws_pass` varchar(50) collate utf8_unicode_ci default NULL,
49 1 walid
  `glpi_user` varchar(50) collate utf8_unicode_ci default NULL,
50 1 walid
  `glpi_pass` varchar(50) collate utf8_unicode_ci default NULL,
51 1 walid
  `is_active` TINYINT NOT NULL default '0', //Activate or not this slave
52 1 walid
  `protocols_id` TINYINT NOT NULL default '1',
53 1 walid
  `entities_id_base` TINYINT NOT NULL default '0', //Source entity ID
54 1 walid
  `is_deflate` TINYINT NOT NULL default '0',
55 1 walid
  `session` varchar(255) collate utf8_unicode_ci default NULL,  
56 1 walid
  `comment` text collate utf8_unicode_ci,
57 1 walid
   PRIMARY KEY  (`id`)
58 1 walid
) ENGINE=MyISAM  DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
59 1 walid
</pre>
60 1 walid
61 1 walid
h3. Changelog table
62 1 walid
63 1 walid
This table logs all changes in the local GLPI. Will be used by a remote GLPI to get changes since last synchronization.
64 1 walid
65 1 walid
<pre>
66 1 walid
DROP TABLE IF EXISTS `glpi_plugin_multiglpi_logs`;
67 1 walid
CREATE TABLE IF NOT EXISTS `glpi_plugin_multiglpi_logs` (
68 1 walid
     `id` int(11) NOT NULL auto_increment,
69 1 walid
     `items_id` int(11) NOT NULL auto_increment,
70 1 walid
     `itemtype` varchar(50) collate utf8_unicode_ci default NULL,
71 1 walid
     `change_type` varchar(50) collate utf8_unicode_ci default NULL, //[add|update|delete|purge]
72 1 walid
     `change_date` datetime NOT NULL,
73 1 walid
   PRIMARY KEY  (`id`)
74 1 walid
) ENGINE=MyISAM  DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
75 1 walid
</pre>
76 1 walid
77 1 walid
h3. Links table
78 1 walid
79 1 walid
This table link an unique object in the source and remote GLPI
80 1 walid
<pre>
81 1 walid
DROP TABLE IF EXISTS `glpi_plugin_multiglpi_links`;
82 1 walid
CREATE TABLE IF NOT EXISTS `glpi_plugin_multiglpi_links` (
83 1 walid
     `id` int(11) NOT NULL auto_increment,    
84 1 walid
     `masters_id` int(11) NOT NULL auto_increment, //ID in the master GLPI
85 1 walid
     `slaves_id` int(11) NOT NULL auto_increment, //ID in the slave GLPI
86 1 walid
     `itemtype` varchar(50) collate utf8_unicode_ci default NULL, //Object's itemtype
87 1 walid
   PRIMARY KEY  (`id`)
88 1 walid
) ENGINE=MyISAM  DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
89 1 walid
</pre>