What's the difference between "strapi.db.connection.context.raw" and "strapi.connections.default.raw"?

What’s the difference between “strapi.db.connection.context.raw” and “strapi.connections.default.raw” in terms of performance and connections usage?

System Information
  • Strapi Version: v4.0.7
  • Operating System: Ubuntu 18.04
  • Database: PostgreSQL 14.6
  • Node Version: 17.9.1
  • NPM Version: 8.11.0


Hey @AlexKorovyansky,

For better understanding see the below image. (Source taken from Bard)

Summary: strapi.connection.default.raw is obsolete option. it’s not available in strapi v4, and was replaced with more powerful strapi.db.connection.context.raw.

Thanks @Shekhar and Bard!

1 Like

Btw, that’s answer from ChatGPT3. It seems Bard has better knowledge of Strapi internals =D

Bard is up to date with the latest information while ChatGPT isn’t :stuck_out_tongue: