Calling Developers!
We are reenergizing our code contribution process! Learn More

How to enable query logging in Spryker's Propel config?

Options
UQ958DA4U
UQ958DA4U Posts: 232 πŸ§‘πŸ»β€πŸš€ - Cadet
edited June 2023 in Propel ORM

Hi! Another short and sweet question: How do you enable query logging in Spryker's Propel config?

Tagged:

Best Answer

  • UKEP86J66
    UKEP86J66 Posts: 208 πŸ§‘πŸ»β€πŸš€ - Cadet
    Answer βœ“
    Options

    A quick answer...add $config[PropelConstants::PROPEL_DEBUG] = true; to your config_local.php

Answers

  • UKEP86J66
    UKEP86J66 Posts: 208 πŸ§‘πŸ»β€πŸš€ - Cadet
    Answer βœ“
    Options

    A quick answer...add $config[PropelConstants::PROPEL_DEBUG] = true; to your config_local.php

  • UKEP86J66
    UKEP86J66 Posts: 208 πŸ§‘πŸ»β€πŸš€ - Cadet
    Options

    Hint - you might want to switch off Jenkins, otherwise the logs will get noisy from the queue tasks

  • UQ958DA4U
    UQ958DA4U Posts: 232 πŸ§‘πŸ»β€πŸš€ - Cadet
    Options

    Thanks!
    Where will Propel store the logs?

  • UQ958DA4U
    UQ958DA4U Posts: 232 πŸ§‘πŸ»β€πŸš€ - Cadet
    Options

    Ah, I found it... it's in the Zed container under /var/log/spryker//propel.log

  • Andriy Netseplyayev
    Andriy Netseplyayev Domain Lead Solution Architecture Sprykee Posts: 519 πŸ§‘πŸ»β€πŸš€ - Cadet
    Options

    if you’re using docker/sdk you can also run docker/sdk logs and see the output, potentially even grep-ing what you want to see