Task doesn't use transaction manager on startup
まだ誰も着手していません。
評価
この issue はまだ評価されていません。
説明
This could be intended behavior, but when an spring cloud task is starting up, it doesn't use the transaction manager when initializing the execution.
Take as an example spring-cloud-task-samples/multiple-datasources. If we change the secondDataSource to disable autocommit, the application will immediately fail on startup because the creation of the execution will be rolled back immediately. after creating it.
@Bean
public DataSource secondDataSource() throws SQLException {
DataSource ds = new EmbeddedDatabaseBuilder()
.setType(EmbeddedDatabaseType.H2)
.build();
SimpleDriverDataSource sdds = ds.unwrap(SimpleDriverDataSource.class);
Properties properties = new Properties();
properties.setProperty("autoCommit", "false");
sdds.setConnectionProperties(properties);
return ds;
}
So either all the initialization code should get wrapped in transaction(s), or the documentation should be updated to reflect that you only support data sources with auto-commit set to true.
- 主要言語
- Java
- スター
- 446
- フォーク
- 310
- 平均マージ
- 18時間 18分
- マージ済み PR(30日)
- 6
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
spring-cloud/spring-cloud-task のほかの issue
-
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
spring-cloud/spring-cloud-task#954 · コメント 1 件 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 30/100
spring-cloud/spring-cloud-task#953 · コメント 1 件 ·
-
status: waiting-on-feedback
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
spring-cloud/spring-cloud-task#952 · コメント 2 件 ·
-
App is failing with 'taskLifecycleListener' bean initialization errors post Spring Boot 3.x upgrade オープンstatus: waiting-on-feedback
難易度 5/5 1週間以上 初心者へのやさしさ 15/100
spring-cloud/spring-cloud-task#950 · コメント 2 件 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 35/100
spring-cloud/spring-cloud-task の issue をすべて見る
似ている issue
-
bug
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
apache/cloudstack#14222 ·
-
[BUG]茶杯方块在取茶时会引发崩溃 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
-
1.0.0-alpha2 Type/Improvement
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
wso2/dpdp-accelerator#272 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
infinispan/infinispan#18150 ·
-
area/frontend
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100