zhongjiajie commented on code in PR #12826:
URL: 
https://github.com/apache/dolphinscheduler/pull/12826#discussion_r1017939754


##########
dolphinscheduler-dao/src/main/resources/sql/dolphinscheduler_postgresql.sql:
##########
@@ -796,6 +797,7 @@ CREATE TABLE t_ds_task_instance (
 ) ;
 
 create index idx_task_instance_code_version on t_ds_task_instance (task_code, 
task_definition_version);
+create index idx_task_instance_process_instance_flag on t_ds_task_instance 
(process_instance_id, flag);

Review Comment:
   > I just use postgresql
   > 
   > and I found there are some foreign key in mysql I think it could be 
removed to improve
   
   But as a PR, you should also add your change to other type of database, such 
as mysql and H2 to keep synchronous.
   Also, you should add the index add in 
https://github.com/apache/dolphinscheduler/blob/489e7fe4e2d980031c91eac2a4823b9f1713659a/dolphinscheduler-dao/src/main/resources/sql/upgrade/3.2.0_schema/postgresql/dolphinscheduler_ddl.sql
 and 
https://github.com/apache/dolphinscheduler/blob/489e7fe4e2d980031c91eac2a4823b9f1713659a/dolphinscheduler-dao/src/main/resources/sql/upgrade/3.2.0_schema/mysql/dolphinscheduler_ddl.sql



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to