[Amarok] Reduce SqlRegistry cache clearing frequency from 6

Maximilian Kossick maximilian.kossick at googlemail.com
Fri Oct 16 21:01:05 CEST 2009


Just to be clear, this timer is not built for clearing the album image
cache. Actually I'm wondering why that is necessary at all, there
aren't any images stored in memory. And the couple of strings can be
kept around until the whole Album object is destroyed.

On Fri, Oct 16, 2009 at 11:36 AM, Mark Kretschmann <kretschmann at kde.org> wrote:
> commit 5fdae6069cfb8723169f31f851c4caa3936b172f
> Author:     Mark Kretschmann <kretschmann at kde.org>
> AuthorDate: Fri Oct 16 11:30:19 2009 +0200
> Commit:     Mark Kretschmann <kretschmann at kde.org>
> CommitDate: Fri Oct 16 11:30:19 2009 +0200
>
>    Reduce SqlRegistry cache clearing frequency from 60s to 300s.
>
>    This should improve performance somewhat, especially for cover image
>    handling.
>
>    CCBUG: 210454
>
> diff --git a/src/collection/sqlcollection/SqlRegistry.cpp b/src/collection/sqlcollection/SqlRegistry.cpp
> index 8d74b47..b3f6570 100644
> --- a/src/collection/sqlcollection/SqlRegistry.cpp
> +++ b/src/collection/sqlcollection/SqlRegistry.cpp
> @@ -35,7 +35,7 @@ SqlRegistry::SqlRegistry( SqlCollection* collection )
>     setObjectName( "SqlRegistry" );
>
>     m_timer = new QTimer( this );
> -    m_timer->setInterval( 60000 );  //try to clean up every 60 seconds, change if necessary
> +    m_timer->setInterval( 300 * 1000 );  //try to clean up every 300 seconds, change if necessary
>     m_timer->setSingleShot( false );
>     connect( m_timer, SIGNAL( timeout() ), this, SLOT( emptyCache() ) );
>     m_timer->start();
>
>
>


More information about the Amarok-devel mailing list