Commit f97b5801 authored by Rafael Monnerat's avatar Rafael Monnerat

Introduced slapos_cache

Slapos_cache include Shacache implementation on Slapos Master, making it also a shacache provider.
The configuraiton was moved from vifib_erp5 to slapos_cache bt5.

On Tests, Includes slapos_cache and reorganise order of bt5 in order to respecting the auromatic, dependencies handling.
parent 8d00f922
No related merge requests found
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ActionInformation" module="Products.CMFCore.ActionInformation"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>action</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>action_type/object_view</string>
</tuple>
</value>
</item>
<item>
<key> <string>category</string> </key>
<value> <string>object_view</string> </value>
</item>
<item>
<key> <string>condition</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>shacache_preference</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
<value>
<tuple>
<string>View</string>
</tuple>
</value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Action Information</string> </value>
</item>
<item>
<key> <string>priority</string> </key>
<value> <float>10.1</float> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Shacache</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
<value> <int>1</int> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/SystemPreference_viewShacache</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -6,6 +6,23 @@
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_local_properties</string> </key>
<value>
<tuple>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>alarm_shacache_website_promise</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
</tuple>
</value>
</item>
<item>
<key> <string>active_sense_method_id</string> </key>
<value> <string>Alarm_checkPromiseShacacheWebSite</string> </value>
......@@ -18,6 +35,16 @@
</tuple>
</value>
</item>
<item>
<key> <string>alarm_shacache_website_promise</string> </key>
<value> <string>embeeded</string> </value>
</item>
<item>
<key> <string>configuration_form_id</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value>
......@@ -30,7 +57,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>promise_vifib_shacache_website</string> </value>
<value> <string>promise_slapos_shacache_website</string> </value>
</item>
<item>
<key> <string>periodicity_day_frequency</string> </key>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Property Sheet" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_count</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>_mt_index</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>_tree</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ShacacheSystemPreference</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Property Sheet</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="Length" module="BTrees.Length"/>
</pickle>
<pickle> <int>0</int> </pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="OOBTree" module="BTrees.OOBTree"/>
</pickle>
<pickle>
<none/>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<global name="OOBTree" module="BTrees.OOBTree"/>
</pickle>
<pickle>
<none/>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Standard Property" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_local_properties</string> </key>
<value>
<tuple>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>mode</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
</tuple>
</value>
</item>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>elementary_type/string</string>
</tuple>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string>Expected State of Shacache websites</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>preferred_shacache_website_expected_state_property</string> </value>
</item>
<item>
<key> <string>mode</string> </key>
<value> <string>w</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Standard Property</string> </value>
</item>
<item>
<key> <string>preference</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>property_default</string> </key>
<value> <string>python: \'\'</string> </value>
</item>
<item>
<key> <string>write_permission</string> </key>
<value> <string>Manage properties</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Folder" module="OFS.Folder"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>slapos_cache</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -62,30 +62,32 @@ if web_site_module is None:\n
shacache = getattr(web_site_module, \'shacache\', None)\n
shadir = getattr(web_site_module, \'shadir\', None)\n
\n
expected_state = context.portal_preferences.getPreferredShacacheWebsiteExpectedState("published")\n
\n
active_result = ActiveResult()\n
if shacache is None:\n
if expected_state == "published" and shacache is None:\n
severity = 1\n
summary = "Shacache WebSite do not exist"\n
detail = ""\n
elif shadir is None:\n
elif expected_state == "published" and shadir is None:\n
severity = 1\n
summary = "Shadir WebSite do not exist"\n
detail = ""\n
elif shacache.getSkinSelectionName() != "SHACACHE":\n
elif expected_state == "published" and shacache.getSkinSelectionName() != "SHACACHE":\n
severity = 1\n
summary = "shacache site don\'t have SHACACHE as skin selection name"\n
detail = ""\n
elif shadir.getSkinSelectionName() != "SHADIR":\n
elif expected_state == "published" and shadir.getSkinSelectionName() != "SHADIR":\n
severity = 1\n
summary = "shadir site don\'t have SHADIR as skin selection name"\n
detail = ""\n
elif shacache.getValidationState() != "published":\n
elif shacache is not None and shacache.getValidationState() != expected_state:\n
severity = 1\n
summary = "shacache site is not published"\n
summary = "shacache site is not what is expected: %s" % expected_state\n
detail = ""\n
elif shadir.getValidationState() != "published":\n
elif shadir is not None and shadir.getValidationState() != expected_state:\n
severity = 1\n
summary = "shadir site is not published"\n
summary = "shadir site is not published %s" % expected_state\n
detail = ""\n
else:\n
severity = 0\n
......
......@@ -54,23 +54,38 @@
shacache = getattr(portal.web_site_module, \'shacache\', None)\n
shadir = getattr(portal.web_site_module, \'shadir\', None)\n
\n
expected_state = context.portal_preferences.getPreferredShacacheWebsiteExpectedState("published")\n
\n
if shacache is None:\n
if expected_state == "published" and shacache is None:\n
shacache = portal.web_site_module.newContent(id=\'shacache\', \n
title="Shacache")\n
\n
if shadir is None:\n
if expected_state == "published" and shadir is None:\n
shadir = portal.web_site_module.newContent(id=\'shadir\',\n
title="Shadir")\n
\n
shacache.setSkinSelectionName("SHACACHE")\n
shadir.setSkinSelectionName("SHADIR")\n
if shadir is None and shacache is None:\n
# Nothing to do\n
return \n
\n
if portal.portal_workflow.isTransitionPossible(shacache, "publish"):\n
if expected_state == "published":\n
shacache.setSkinSelectionName("SHACACHE")\n
shadir.setSkinSelectionName("SHADIR")\n
\n
if expected_state == "published":\n
if portal.portal_workflow.isTransitionPossible(shacache, "publish"):\n
shacache.publish()\n
\n
if portal.portal_workflow.isTransitionPossible(shadir, "publish"):\n
if portal.portal_workflow.isTransitionPossible(shadir, "publish"):\n
shadir.publish()\n
return\n
\n
\n
if portal.portal_workflow.isTransitionPossible(shacache, "embeed"):\n
shacache.embeed()\n
\n
if portal.portal_workflow.isTransitionPossible(shadir, "embeed"):\n
shadir.embeed()\n
</string> </value>
</item>
<item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5Form" module="Products.ERP5Form.Form"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>action</string> </key>
<value> <string>Base_edit</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>edit_order</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>enctype</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>group_list</string> </key>
<value>
<list>
<string>left</string>
<string>right</string>
<string>center</string>
<string>bottom</string>
<string>hidden</string>
</list>
</value>
</item>
<item>
<key> <string>groups</string> </key>
<value>
<dictionary>
<item>
<key> <string>bottom</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>center</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>hidden</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>left</string> </key>
<value>
<list>
<string>my_preferred_shacache_website_expected_state</string>
</list>
</value>
</item>
<item>
<key> <string>right</string> </key>
<value>
<list/>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>SystemPreference_viewShacache</string> </value>
</item>
<item>
<key> <string>method</string> </key>
<value> <string>POST</string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string>SystemPreference_viewVifib</string> </value>
</item>
<item>
<key> <string>pt</string> </key>
<value> <string>form_view</string> </value>
</item>
<item>
<key> <string>row_length</string> </key>
<value> <int>4</int> </value>
</item>
<item>
<key> <string>stored_encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Vifib</string> </value>
</item>
<item>
<key> <string>unicode_mode</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>update_action</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>update_action_title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>items</string>
<string>title</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>my_preferred_shacache_website_expected_state</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>items</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_list_field</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>items</string> </key>
<value>
<list>
<tuple>
<string>Embeeded</string>
<string>embeeded</string>
</tuple>
<tuple>
<string>Published</string>
<string>published</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Preferred Shacache WebSite Expected State</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
erp5_web_shacache
erp5_web_shadir
\ No newline at end of file
1
\ No newline at end of file
System Preference | shacache_preference
\ No newline at end of file
1
\ No newline at end of file
portal_alarms/promise_slapos_shacache_website
\ No newline at end of file
ShacacheSystemPreference
\ No newline at end of file
slapos_cache
\ No newline at end of file
slapos_cache
\ No newline at end of file
0.1
\ No newline at end of file
slapos_category
slapos_cloud
slapos_slap_tool
slapos_cache
\ No newline at end of file
23
\ No newline at end of file
24
\ No newline at end of file
......@@ -9,8 +9,6 @@ erp5_tiosafe_core
erp5_ui_test
erp5_ui_test_core
erp5_web
erp5_web_shacache
erp5_web_shadir
vifib_agent
vifib_base
vifib_configurator
......
530
\ No newline at end of file
531
\ No newline at end of file
......@@ -47,7 +47,6 @@ class testVifibMixin(ERP5TypeTestCase):
result = [
'erp5_core_proxy_field_legacy',
'erp5_full_text_myisam_catalog',
'erp5_xhtml_style',
'erp5_ingestion_mysql_innodb_catalog',
'erp5_base',
'erp5_jquery',
......@@ -70,9 +69,9 @@ class testVifibMixin(ERP5TypeTestCase):
'erp5_knowledge_pad',
'erp5_credential',
'erp5_tax_resource',
'erp5_web_download_theme',
'slapos_cloud',
'erp5_open_trade',
'erp5_web_download_theme',
'erp5_tiosafe_core',
'erp5_system_event',
'erp5_simplified_invoicing',
......@@ -92,11 +91,16 @@ class testVifibMixin(ERP5TypeTestCase):
'erp5_bearer_token',
'erp5_administration',
'erp5_accounting_l10n_fr',
'erp5_web_shacache',
'erp5_data_set',
'vifib_open_trade',
'vifib_base',
'erp5_workflow',
'erp5_web_shadir',
'vifib_slap',
'vifib_slapos_rest_api_tool_portal_type',
'erp5_workflow',
'erp5_configurator',
'slapos_cache',
'slapos_slap_tool',
'slapos_category',
'vifib_payzen',
......@@ -104,9 +108,7 @@ class testVifibMixin(ERP5TypeTestCase):
'erp5_upgrader',
'vifib_slapos_rest_api',
'vifib_data',
'erp5_configurator',
'erp5_web_shacache',
'erp5_data_set',
'slapos_configurator',
'erp5_ui_test_core',
'slapos_erp5',
'vifib_web',
......@@ -117,10 +119,8 @@ class testVifibMixin(ERP5TypeTestCase):
'vifib_data_web',
'vifib_data_simulation',
'vifib_data_payzen',
'slapos_configurator',
'vifib_configurator',
'vifib_agent',
'erp5_web_shadir',
'erp5_ui_test',
# All business templates above are the dependency
# tree of vifib_erp5, so if you mofify this list
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment