Symfony 1.4 with sfPropelORMPlugin and MySQL Replication - mysql

I upgraded my symfony 1.4 project with the latest version of sfPropelORMPlugin and I created my runtime-conf.xml according to: http://www.propelorm.org/cookbook/replication.html with the intend to write my sql to a master and read from the slaves.
I'm rebuilding my model with symfony propel:build-model and everything goes fine but both write/read SQL statements are sent to the master. I'm not sure I understand how propel is using runtime-conf.xml within the symfony framework.
Am I missing an extra step?

Related

mysql multiple dependency in gradle

I'm a backend developer who worked in South Korea.
I'm experiencing a mysql dependency conflict.
I want to use two data sources (DB: mysql) in a spring boot project, but the mysql version is different (one is 5.0 and the other is 8.0).
So, I add a dependency like this in build.gradle.
runtimeOnly("mysql:mysql-connector-java:5.0.4")
runtimeOnly("mysql:mysql-connector-java:8.0.22")
However, if the group and name are the same, Gradle only supports one dependency.
Who could think like this, the MySQL 8.0 connector can connect to the most recent MySQL version, so I verified that the MySQL 8.0 driver can connect to the most recent MySQL version, which is 5.7.
The other method I discovered is that MySQL 5.0 is connected via mysql-connector-java, and MySQL 8.0 is connected via mariadb-java-client.
But I don`t want to solve this problem like this... This is just makeshift.
Please give me another way. Thank you
In Gradle, how do you install multiple versions of the same dependency? 

Is migration file must in Sequelize?

I started my project with sequeliz-cli by running init command.
but i deleted the migrations and seeder folder. and started creating the models.
i need to first create a db in workbench, and then ran db.sync() from sequelize, which created the tables in db. Its running kind of fine.
can we complete the whole project without using migrate and deploy it on production env, will not using migrate disadvantageous??
Migrations help you to use different versions of your app and DB in different production environments and change your DB structure as long as to add some initial data precisely.
sync method would be dangerous in such scenarios with different versions in a situation when you run a newer version of your app on an older DB occasionally.
If you have a simple DB structure that won't change or will be the same on all prods then you can use sync.

SonarQube 6.1 not calculating lines of code after upgrade and database migration

tl;dr: SonarQube calculates lines of code metric for some projects but not others after an upgrade.
Hello everyone,
I recently took over an orphaned SonarQube 5.1 installation running on MySQL 5.1 on another server. When I upgraded SQ to 5.6.2 it told me that it required MySQL 5.6. Because the servers in question are CentOS 7 that version of MySQL is not available through yum. Use of yum is required for installing software. I installed PostgreSQL on the SQ server and, because I did not want to lose SQ history and configuration, migrated the database from MySQL to Postgres using pgloader (see pgloader.conf in code block below). The migration appeared to have worked as the schema changes 5.1->5.6.2 succeeded as did 5.6.2->6.1.
LOAD DATABASE
FROM mysql://USER:PASSWORD#mysqlhost.my.com/sonar
INTO postgresql://USER:PASSWORD#pghost.my.com/sonar
with create indexes, preserve index names;
However, some projects that existed before the upgrade and migration and also some projects that have been added (through Jenkins) after the migration never have the Lines of Code metric calculated. These are primarily but not exclusively C# files.
I don't see any way to "reset" a project in the UI or web API. If I could export the SQ configuration, I would wipe the database and reload, but I don't see a way to do that either. Starting from scratch is undesirable. Any help is greatly appreciated.

How can I view my MySQL database created by Entityframework 6

I use Entity framework 6 and MySQL 5.5
When I use code first to create the my sql database, the database is created successfully, but when I open mysql workbench, I can't find it in MySQL workbench.
I have used EF 5.0 code before to create a database and the database can be found in MySQL workbench.
has anyone met this issue before?
I'll bet an arm and a leg you haven't configured EF correctly an it is using it's default database instead of mysql, look here or here
The easiest way to verify that is to shut down your MySQL server and test if your can still query your database with EF or not.

MySQL to SQL Server Migration and Hibernate/Spring MVC

We are migrating a database from MySQL to SQL Server. The migration is pretty straight forward and can be done quite quickly. The project using the existing MySQL database is using Hibernate within Spring MVC. If I migrated the database to SQL Server, and updated the dialect on the Spring MVC side, should the project just work without any other changes to Hibernate queries? Or do we have to make changes to every database call in the data access layer in Spring MVC? I guess I'm trying to find out where the pain points will be and if we could run into any huge issues.
It depends on dependency of your application on database features, are you using stored procedures? MySQL special functions in your HQLs? and ... If you have not used any, I believe everything will go fine