Unable to delete node because of too many sub nodes

Author Message

Eirik Alfstad Johansen

Tuesday 10 October 2006 10:43:28 am

Hi,

I recently stumbled across a message (in v. 3.8.4) I've never seen before while trying to delete a node. Here it is, freely translated from Norwegian:

[quote]
Warnings:

The lines that are marked with red contain more than the maximum amount of nodes that can be removed this way. They will not be removed. You can remove them using the script "Subtree Remove".
[/quote]

I've never heard of such a script, and I'm unable to locate any information about it (and the ez.no search being unavailable doesn't help).

Does anyone know anything about this script?

Thanks in advance !

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Łukasz Serwatka

Tuesday 10 October 2006 10:52:27 am

Hi Eirik,

This script is placed under bin/php/ezsubtreeremove.php and takes 2 parameters.

Options:
  --nodes-id=VALUE  Subtree nodes ID (separated by comma ',').
  --ignore-trash    Ignore trash ('move to trash' by default).

Execute it from root node.

php bin/php/ezsubtreeremove.php

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Kristof Coomans

Tuesday 10 October 2006 10:59:13 am

It's in a doc for eZ 3.9: http://pubsvn.ez.no/nextgen/trunk/doc/features/3.9/ezsubtreeremove_script.txt

The changelog of 3.8.4 (<i>http://ez.no/download/ez_publish/changelogs/ez_publish_3_8/changelog_3_8_3_to_3_8_4</i>) mentions some related INI setting:
<i>Added content.ini[RemoveSettings].MaxNodesRemoveSubtree Maximum number of nodes to remove (using Remove Subtrees feature)</i>, so I guess it was added in this 3.8 release.

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Eirik Alfstad Johansen

Tuesday 10 October 2006 11:02:29 am

Hi guys,

Thanks for your prompt response. After doing some additional searching, I came across this bug report which explained the problem:

http://ez.no/de/community/bugs/remove_many_objects_does_not_work_correctly

However, the script is not available withj the 3.8.4 distro (not mine, at least), so I had to add it manually.

Thanks anyway !

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Kristof Coomans

Wednesday 01 November 2006 1:08:49 am

My fresh 3.8.6 install misses it too.

I'll report this as a bug ( http://issues.ez.no/IssueView.php?Id=9313 ).

Thanks for noticing!

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Vytautas Germanavičius

Thursday 02 November 2006 10:25:23 am

i think , in this case deleting should be done directly in database, because deleting, when you need to create ph objects, to make thousands of queries takes a lot of time. Any extension which i try, and which is using ez php framework - gives me timeout...

For example, i need to delete 22 000 nodes. No extenstion at the moment can do this. With PHP - forget about it...

{set-block scope=root variable=cache_ttl}0{/set-block}

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 19 2025 01:13:42
Script start
Timing: Jan 19 2025 01:13:42
Module start 'layout'
Timing: Jan 19 2025 01:13:42
Module start 'content'
Timing: Jan 19 2025 01:13:43
Module end 'content'
Timing: Jan 19 2025 01:13:43
Script end

Main resources:

Total runtime0.7802 sec
Peak memory usage4,096.0000 KB
Database Queries70

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0050 589.3047152.6406
Module start 'layout' 0.00500.0022 741.945339.4766
Module start 'content' 0.00710.7717 781.4219669.8906
Module end 'content' 0.77880.0014 1,451.312516.1250
Script end 0.7801  1,467.4375 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00320.4118160.0002
Check MTime0.00130.1690160.0001
Mysql Total
Database connection0.00080.108510.0008
Mysqli_queries0.710991.1241700.0102
Looping result0.00080.0991680.0000
Template Total0.755996.920.3780
Template load0.00200.260620.0010
Template processing0.753996.631720.3770
Template load and register function0.00010.013210.0001
states
state_id_array0.00080.104710.0008
state_identifier_array0.00070.092020.0004
Override
Cache load0.00180.2299410.0000
Sytem overhead
Fetch class attribute can translate value0.00070.084640.0002
Fetch class attribute name0.00140.1809100.0001
XML
Image XML parsing0.00230.292240.0006
class_abstraction
Instantiating content class attribute0.00000.0023120.0000
General
dbfile0.00140.1833360.0000
String conversion0.00000.000940.0000
Note: percentages do not add up to 100% because some accumulators overlap

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
10content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
3content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
2content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 29
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs