Forums / Developer / Subversion and var/storage

Subversion and var/storage

Author Message

Greg McAvoy-Jensen

Friday 06 June 2008 11:33:22 pm

I've read posts about handling var/cache and var/log with svn:ignore. That makes sense. But should var/storage be handled the same way? What makes the most sense?

Granite Horizon, Certified Developer of eZ Publish Web Solutions
Provider of the SaaS Solution Granite Horizon In The Cloud | http://granitehorizon.com/cloud
http://granitehorizon.com | +1 916 647 6350 | California USA | @granitegreg
Blog: http://granitehorizon.com/blog

Gaetano Giunta

Saturday 07 June 2008 2:41:09 am

It makes sense to svn:ignore var/storage too for the two simple reasons:

- it will grow very big very fast, and putting it in svn will make your svn crawl to a grinding halt - especially if you keep your workspace on windows (not even taking into account a possible antivirus), but on unix too (just svn delete of the var/storage dir when linked to repo over https over internet took me an hour or so)

- as soon as you have made a first copy of your dev server install to a test, integration or production setup, the different installs will diverge as for content present. Devs will create test content in the dev eZ to check out new templates, editors will usually start to fill in real content in the integration or prod installs, etc. Some identical content will be created by hand in both eZP installs, resulting in different files in var/storage

In short: have svn ignore it. When you need to resync your data from eg. prod to dev, copy over at the same time both the db and the storage, and you're done

Principal Consultant International Business
Member of the Community Project Board

Greg McAvoy-Jensen

Saturday 07 June 2008 6:39:53 am

Thanks, Gaetano.

That's what I thought, but wanted to be sure I wasn't missing something since the article (http://ez.no/developer/articles/using_subversion_with_ez_publish) listed var/cache and var/log but not var/storage or simply "var".

Granite Horizon, Certified Developer of eZ Publish Web Solutions
Provider of the SaaS Solution Granite Horizon In The Cloud | http://granitehorizon.com/cloud
http://granitehorizon.com | +1 916 647 6350 | California USA | @granitegreg
Blog: http://granitehorizon.com/blog

Greg McAvoy-Jensen

Monday 23 June 2008 11:30:45 am

One follow-up question: does this mean that if we're using the ignore property on the var directory, we should never use svn commit from the root ezpublish directory?

I'm new to SVN, and assumed after doing whatever changes I wanted (template override settings, extension design, etc.) I would then just do a svn commit from the root ezpublish directory--but this updates the var directory even with propset ignore. Am I missing something?

And is the same true on the testing and production servers--we should only use svn update on the specific directories we've made changes to? It seems to make us more prone to errors.

Thanks for any thoughts.

Granite Horizon, Certified Developer of eZ Publish Web Solutions
Provider of the SaaS Solution Granite Horizon In The Cloud | http://granitehorizon.com/cloud
http://granitehorizon.com | +1 916 647 6350 | California USA | @granitegreg
Blog: http://granitehorizon.com/blog

Maxime Thomas

Wednesday 26 January 2011 6:02:36 pm

Hi Greg,

Another point you can focus on : some extension are generating data inside the extension and not inside the var directory.

Typically ezfind has its own index under /extensions/ezfind/java/solr/data.

Max

Maxime Thomas
maxime.thomas@wascou.org | www.wascou.org | http://twitter.com/wascou

Company Blog : http://www.wascou.org/eng/Company/Blog
Technical Blog : http://share.ez.no/blogs/maxime-thomas

Gaetano Giunta

Saturday 29 January 2011 2:33:17 am

@maxime a good point. And I think we should in fact fix those extensions,as the 'ez' way is to only have variable data in /var.

Apart form ezfind, any other known offender?

Principal Consultant International Business
Member of the Community Project Board

eZ debug

Timing: Jan 17 2025 23:40:05
Script start
Timing: Jan 17 2025 23:40:05
Module start 'content'
Timing: Jan 17 2025 23:40:06
Module end 'content'
Timing: Jan 17 2025 23:40:06
Script end

Main resources:

Total runtime1.0323 sec
Peak memory usage4,096.0000 KB
Database Queries205

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0061 587.7109180.8359
Module start 'content' 0.00610.8709 768.5469634.4609
Module end 'content' 0.87700.1552 1,403.0078341.0625
Script end 1.0322  1,744.0703 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00430.4145210.0002
Check MTime0.00150.1501210.0001
Mysql Total
Database connection0.00120.118510.0012
Mysqli_queries0.935290.60072050.0046
Looping result0.00240.23472030.0000
Template Total1.006997.520.5034
Template load0.00200.192520.0010
Template processing1.004997.345520.5024
Template load and register function0.00020.015710.0002
states
state_id_array0.00100.094610.0010
state_identifier_array0.00150.146620.0008
Override
Cache load0.00170.1651310.0001
Sytem overhead
Fetch class attribute can translate value0.00190.181140.0005
Fetch class attribute name0.00180.176290.0002
XML
Image XML parsing0.00270.260940.0007
class_abstraction
Instantiating content class attribute0.00000.0024120.0000
General
dbfile0.00410.4008410.0001
String conversion0.00000.000630.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
6content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
6content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
6content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 20
 Number of unique templates used: 5

Time used to render debug report: 0.0002 secs