Skip Menu |
 

This queue is for tickets about the HTML-CTPP2 CPAN distribution.

Report information
The Basics
Id: 50521
Status: open
Priority: 0/
Queue: HTML-CTPP2

People
Owner: Nobody in particular
Requestors: andrey [...] kostenko.name
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Download (untitled) / with headers
text/plain 226b
If structure has backreferences, even weaked, HTML::CTPP2 hangs, eats our RAM and stores its dump in /spool/core :-) e.g.: $tree->{children} = [ { name => 'ch1', parent => $tree }, { name => 'ch1', parent => $tree }, ]
Download (untitled) / with headers
text/plain 385b
Чтв. Окт. 15 07:59:21 2009, GUGU писал: Show quoted text
> If structure has backreferences, even weaked, HTML::CTPP2 hangs, eats > our RAM and stores its dump in /spool/core :-) > e.g.: > $tree->{children} = [ > { name => 'ch1', parent => $tree }, > { name => 'ch1', parent => $tree }, > ]
Never use backreferences in your data structures, it's crap. This is no bug, no fixes need.
Download (untitled) / with headers
text/plain 727b
Чтв. Окт. 15 09:05:45 2009, http://slonik-v-domene.livejournal.com/ писал: Show quoted text
> Чтв. Окт. 15 07:59:21 2009, GUGU писал:
> > If structure has backreferences, even weaked, HTML::CTPP2 hangs, eats > > our RAM and stores its dump in /spool/core :-) > > e.g.: > > $tree->{children} = [ > > { name => 'ch1', parent => $tree }, > > { name => 'ch1', parent => $tree }, > > ]
> > Never use backreferences in your data structures, it's crap. > > This is no bug, no fixes need.
Crap is a module, which can't handle them :-) There are a lot of useful cyclic structures. Perl has a feature, which allows to work with cyclic structures (weak references) and a lot of modules creates back-referenced structures.
Download (untitled) / with headers
text/plain 335b
Show quoted text
> Crap is a module, which can't handle them :-)
Really? Show quoted text
> There are a lot of useful cyclic structures. Perl has a feature, which > allows to work with cyclic structures (weak references) and a lot of > modules creates back-referenced structures.
Backreferences as template parameters are completely bad data structure. By design.
Download (untitled) / with headers
text/plain 759b
Чтв. Окт. 15 09:50:36 2009, http://slonik-v-domene.livejournal.com/ писал: Show quoted text
> > Crap is a module, which can't handle them :-)
> > Really? >
Really. Imagine that all modules will use all your memory and make a segfault instead of pretty error messages. Show quoted text
> > There are a lot of useful cyclic structures. Perl has a feature, which > > allows to work with cyclic structures (weak references) and a lot of > > modules creates back-referenced structures.
> > Backreferences as template parameters are completely bad data > structure. By design.
I don't want to remove link to parent in my tree only because you think that "Backreferences as template parameters are completely bad data structure". I already have a structure, which I want to display.
Download (untitled) / with headers
text/plain 927b
Show quoted text
> > > Crap is a module, which can't handle them :-)
> > > > Really? > >
> Really. Imagine that all modules will use all your memory and make a > segfault instead of pretty error messages.
I have simple solution that 100% works: Just throw away this data structure. CTPP works in Rambler (http://rambler.ru/) and handles billions of requests without any problem. Show quoted text
> > > There are a lot of useful cyclic structures. Perl has a feature,
which Show quoted text
> > > allows to work with cyclic structures (weak references) and a lot
of Show quoted text
> > > modules creates back-referenced structures.
> > > > Backreferences as template parameters are completely bad data > > structure. By design.
Show quoted text
> I already have a structure, which I want to display.
1. Switch to another template engine. OR 2. Write patch for YOUR code and remove backreferences OR 3. Write patch for CTPP2.xs and send it to me Currently, I have no time to fix this feature.
Download (untitled) / with headers
text/plain 1.2k
Чтв. Окт. 15 10:17:17 2009, http://slonik-v-domene.livejournal.com/ писал: Show quoted text
> > > > Crap is a module, which can't handle them :-)
> > > > > > Really? > > >
> > Really. Imagine that all modules will use all your memory and make a > > segfault instead of pretty error messages.
> > I have simple solution that 100% works: > > Just throw away this data structure. CTPP works in Rambler > (http://rambler.ru/) and handles billions of requests without any > problem. >
> > > > There are a lot of useful cyclic structures. Perl has a feature,
> which
> > > > allows to work with cyclic structures (weak references) and a lot
> of
> > > > modules creates back-referenced structures.
> > > > > > Backreferences as template parameters are completely bad data > > > structure. By design.
>
> > I already have a structure, which I want to display.
> > 1. Switch to another template engine. > > OR > > 2. Write patch for YOUR code and remove backreferences > > OR > > 3. Write patch for CTPP2.xs and send it to me > > Currently, I have no time to fix this feature.
I've switched back to Template::Toolkit. This bugreport is only an answer for users' questions like "WTF my program receives segfault?" Maybe somebody will fix it


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.