Form Caches: Difference between revisions
No edit summary |
Karla Matus (talk | contribs) No edit summary |
||
Line 1: | Line 1: | ||
El software iHRIS realizá caché de los datos guardados en la base de datos (o archivo XML , o servidor LDAP) para tener acceso más rápido y la habilidad de crear índices. Estos cachés se utilizan, por ejemplo, para llenar informes y listas. | |||
A los datos para un formulario ''XXXXX'' se les puede haber realizado caché en una ''hippo_XXXXX.'' Esta tabla hippo puede utilizarse para: | |||
* | *Generar informes para [[Custom Reporting -- An Overview | Custom Reporting]] | ||
* | *Exportar datos para [[Managing Decentralized iHRIS Manage with Launchpad|decentralized data management]] | ||
==Hippo | ==Estructura de la Tabla Hippo== | ||
Si un formulario XXXXX tiene un campo YYYYY entonces la tabla hippo_XXXXX tendrá una columna `XXXXX+YYYYY.` También hay una columna `XXXXX+id` que contiene la id del formulario y una columna `XXXXX+parent` que contiene el formulario primario, si lo hay. | |||
== | ==Momentos de Caché y Línea de Comando== | ||
Las tablas hippo se generan mediante un proceso de fondo una vez que el caché de un formulario se considera obsoleto. Vea el documento [[Configuring Form Cache Generation Timing]] para mayor información en el momento para los cachés de formularios y acerca de la creación manual de los cachés de formularios desde la línea de comando. | |||
To see this tutorial for different versions of the software see the following:{{otherversions|Exporting and Updating Form Caches Using Profiles}} | To see this tutorial for different versions of the software see the following:{{otherversions|Exporting and Updating Form Caches Using Profiles}} |
Revision as of 11:23, 29 September 2013
El software iHRIS realizá caché de los datos guardados en la base de datos (o archivo XML , o servidor LDAP) para tener acceso más rápido y la habilidad de crear índices. Estos cachés se utilizan, por ejemplo, para llenar informes y listas.
A los datos para un formulario XXXXX se les puede haber realizado caché en una hippo_XXXXX. Esta tabla hippo puede utilizarse para:
- Generar informes para Custom Reporting
- Exportar datos para decentralized data management
Estructura de la Tabla Hippo
Si un formulario XXXXX tiene un campo YYYYY entonces la tabla hippo_XXXXX tendrá una columna `XXXXX+YYYYY.` También hay una columna `XXXXX+id` que contiene la id del formulario y una columna `XXXXX+parent` que contiene el formulario primario, si lo hay.
Momentos de Caché y Línea de Comando
Las tablas hippo se generan mediante un proceso de fondo una vez que el caché de un formulario se considera obsoleto. Vea el documento Configuring Form Cache Generation Timing para mayor información en el momento para los cachés de formularios y acerca de la creación manual de los cachés de formularios desde la línea de comando.
To see this tutorial for different versions of the software see the following:
Editing, Exporting and Updating Form Caches Using Profiles
In version 4.0.6 we add the ability to create profiles of form caches. A profile is a simply a list of forms that you can use to rapidly:
- Update the cache for each of the forms in the profile
- Export the cache, via a mysqldump, for each of the forms in the profile. This is particularly useful for exporting data from a regional or district office to the national level.
This functionality is part of the Cached Forms modules and can be accessed by clicking on the links for Configure System and then Cached Forms
Creating A Profile
The first step is to create a profile of the forms. A profile is a list of forms with a short name that you can use to help you identify the list.
- Look under Create/Edit Profile on the Cached Forms page. Here make sure "Create a new profile" is selected in the drop-down, and then click the "Edit" button.
- Now type a name for the profile. It is best to keep it short with limited punctuation such as "nightly_update"
- Now select each of the forms you wish to include in the profile
- Finally, click the "Submit" button at the bottom of the page
Updating the Cache of a Profile
You can update all of the forms in a profile under Cache Forms on the Cached Forms page.
- Choose the profile for which you wish to cache forms
- Click the "Cache" button
Exporting the Cache of a Profile
There are two main usages of exporting all of the forms in profile, you can either get all the data, or only the modifications to the data since the last date. Both can be accessed under Export Cached Forms on the Cached Forms page.
- Choose the profile you wish to export
- Choose to enable bzip2 compression or not
- Optionally select the modification time.
- If you do not set the modification time, you will get all of the data for the forms. The mysqldump will include "DROP TABLE IF EXISTS" and "CREATE" statements for each of the hippo_XXXX tables. Data is populated via "INSERT" statements
- If you do not set the modification time, you will get all of the data for the forms. The mysqldump will include neither the "DROP TABLE IF EXISTS" nor the "CREATE" statement for each of the hippo_XXXX tables. Data is populated via "REPLACE" statements.
- click the "Export" button
Note: When you export the cache, it does not first update it. You will need to do this manually.
Crontab and Command Line Interaction
For example, you may wish to put an update of the profile "nightly_update" in your crontab:
30 1 * * * /usr/bin/php /var/www/ihris-manage/index.php --page=/CachedForms/cache --get=profile=nightly_update
will cause all forms in the 'nightly_update' profile to be update at 1:30am. Putting:
10 * * * * /usr/bin/php /var/www/ihris-manage/index.php --page=/CachedForms/cache --get=profile=hourly_update
in your profile will update every form in the 'hourly_update' profile at ten minutes past the hour.