| Rev |
Age |
Author |
Path |
Log message |
Diff |
| 37588 |
25 d 8 h |
amit |
/trunk/profitmandi-dao/src/main/ |
Serve partner investment from a 2-minute snapshot instead of a 3-hour cache
getInvestment() was @Cacheable on a 3-hour Redis cache that addAmountToWallet
evicted but consumeAmountFromWallet did not. A partner whose advance payment was
swept straight to a loan had the money counted twice - once as a still-cached
wallet balance, once as the reduced utilisation - overstating their credit limit
by the payment x their tier until the cache expired.
Replaced with fofo.partner_investment, refreshed every 2 minutes by
PartnerInvestmentSweepService. Every coupled term is read in one pass, so wallet
and utilisation (and in-stock and aged-Apple) can never come from different
moments. A shorter TTL would only have made the error rarer - it scales with the
payment, not the delay.
- PartnerInvestment entity/repository + partner_investment_snapshot.sql
- PartnerInvestmentSweepService: 9 batched reads, stores base_value for change
detection, refreshes aged-Apple for partners whose stock moved intra-day
- getInvestment/getInvestmentsForFofoStores both read the snapshot, so the two
paths no longer disagree; live compute retained as fallback
- selectActivatedStockAmountByFofoIds: batches an N+1 that cost 233ms x 1690
partners (6.6 min -> 1.0 s)
- getFirstBillingDates: batches another N+1 (4.6 s -> 0.67 s)
- selectPendingGrnOrders(List) now applies the same SD_START_DATE floor as the
single-partner overload; the two were reporting different GRN-pending
- selectPartnerStockValueMap takes excludeActivated: an activated Apple handset
held past the aging window was added once to in-stock and subtracted twice
(activated stock, then the aged haircut). 90 units, 24 partners, Rs 65.19 lakh
double-deducted. Live-demo passes false - no overlap there.
- applyManualAdjustment: routes the two hand-rolled admin wallet adjustments
through WalletServiceImpl so they take the FOR UPDATE lock
- add_idx_order_grn_pending.sql: covering index, GRN query 1320ms -> 514ms |
|
| 36518 |
148 d 10 h |
aman |
/trunk/ |
Fix:Fix first po and edge case for bulk order |
|
| 35856 |
222 d 8 h |
amit |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/ |
Optimize activated stock query (no cache), move offer cache to Redis, add bulk publish and delete offer |
|
| 33306 |
887 d 11 h |
amit.gupta |
/trunk/ |
Fixed logic for sale in inventory history |
|
| 33182 |
915 d 6 h |
shampa |
/trunk/ |
add fields in price drop table. Add purchase billing summery and sale summery table. |
|
| 33120 |
932 d 7 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
patch for |
|
| 33115 |
932 d 12 h |
shampa |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
spelling correction |
|
| 33023 |
951 d 6 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/ |
fixed InventoryItem |
|
| 33015 |
952 d 5 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/ |
Fixed added lower case |
|
| 31860 |
1256 d 10 h |
tejbeer |
/trunk/ |
change |
|
| 31163 |
1419 d 9 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
Fixed |
|
| 30652 |
1565 d 8 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/ |
Added sellin margin payout |
|
| 30523 |
1590 d 14 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
Fixed ahead issue |
|
| 29571 |
1792 d 5 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
|
|
| 29095 |
1862 d 10 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
|
|
| 29093 |
1862 d 11 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
|
|
| 26304 |
2438 d 12 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/ |
|
|
| 26303 |
2438 d 14 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
|
|
| 26299 |
2438 d 20 h |
amit.gupta |
/trunk/ |
Added activation as seperate table |
|
| 26213 |
2452 d 13 h |
amit.gupta |
/trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/entity/fofo/ |
|
|