Generated list pages resolve their relation label maps one lookup after another

Aperta Adatta ai principianti
#8,354 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
82/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
javascript
Ambito
performance

Direzione di ricerca

Leggi loadLookups() in manage/list-page.js.template e list/page.js.template, poi verifica come ogni lookup gestisce attualmente gli errori. La issue richiede che i lookup indipendenti vengano eseguiti in parallelo, mantenendo la gestione degli errori di ciascuno. Il lavoro è completato quando le etichette appaiono dopo il lookup più lento, anziché dopo la somma dei round trip.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Issue

`loadLookups()` in the generated `manage/list-page.js.template` and `list/page.js.template` fetches the referenced rows of each relationship column one `await` at a time:

```js
const optCompany = await App.services.api.getAll('/.../CompanyController.java', { baseUrl: '' });
...
const optCurrency = await App.services.api.getAll('/.../CurrencyController.java', { baseUrl: '' });
```

The list itself does not wait for them (`loadLookups()` is not awaited), but every FK column shows its raw key until the LAST lookup of the chain has answered, so on a list with 8-10 relation columns the labels arrive after the sum of the round trips rather than the slowest one.

Found while fixing the same shape on the forms (#8344).

Expected

The lookups are independent and load concurrently (`Promise.all`, each keeping its own error handling), so the labels land after the slowest lookup, not after all of them in series.

Lingua principale
Java
Stelle
278
Fork
97
Merge medio
15h 33m
PR unite (30g)
314

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di eclipse-dirigible/dirigible

Tutte le issue di eclipse-dirigible/dirigible

Issue simili

Altre issue su Java

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.