JetBrains / JetBrains/Exposed

Allow to deactivate entity cache

オープン
#653 コメント 4 件 リアクション 0 件 担当者 0 名 GitHub で見る
enhancement
主要言語
Kotlin
スター
9.3k
フォーク
798
平均マージ
4日 2時間
マージ済み PR(30日)
26

説明

I use Table to create/update/delete data in DB.
I use Entity (DAO) for some simple read.
I use Entity with a custom Query done with a Table then call `Entity.wrapRows(...).toList()`.

When using wrapRows I get cached entities which is absolutely wrong, I would like to get the actual ResultRow transformed into an Entity with the proper data.

![entity_cache_ignore_row_result](https://user-images.githubusercontent.com/3595693/66374718-356f2a00-e9de-11e9-8c2a-195418bdb1a5.png)

Due to this behavior, I can get entities with old values inside the current transaction cache but those entities have been modified in other transaction which have been committed already.
@Tapac

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

Start by tracing the Entity.wrapRows(...).toList() path and the entity-cache behavior described in the issue. Determine how cache deactivation should be exposed, then verify that wrapped query rows produce entities with current ResultRow values rather than cached data.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
kotlin, sql
領域
database
issue の種類
機能追加
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
45/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。