[Question/Wishlist] Using JSON for the protocol instead of XML
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 18/100
Direzione di ricerca
Inizia esaminando i percorsi di comunicazione tra server e client che implementano il protocollo XML esistente. L’issue indica esempi di mapping in Rust in plugin-2021/src/game/game_state.rs e client-base/src/protocol/room.rs; determina l’ambito completo della migrazione e definisci i criteri di accettazione per una comunicazione JSON equivalente tra client e server.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
This is more of a general question rather than a specific issue. Has using JSON instead of XML for the protocol ever been considered, apart from legacy reasons?
While such a change would have quite a big impact on the way the different clients and the server handle communication, I think there are strong reasons for at least considering such a change e.g. for the next year:
- JSON is ubiquitous, simple and easy to parse/serialize in almost every mainstream language (even hand-rolling a parser isn't too hard)
- JSON maps very naturally to data structures in almost every mainstream language (in contrast to XML, where especially serialization can be very ambiguous, with regard to whether e.g. something should be serialized as text, an element, an attribute, etc.)
- JSON is human-readable, debuggable and quite a bit less verbose than XML
A particular pain point with XML that I've encountered myself is e.g. the lack of good library support for Rust, leaving us essentially with either the option of hand-writing the XML mappings (which is tedious and error-prone) or using pretty limited tools for defining automatic mappings between structs and XML, which still require careful manual review of certain edge cases.
While these problems might not apply (as much) to other languages, JSON would solve pretty much all of these issues and at the same time simplify the protocol in general.
- Lingua principale
- HTML
- Stelle
- 13
- Fork
- 14
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di software-challenge/backend
-
Encoding Issues with umlautsForse di nuovo libera @xeruf l’ha presa 847 giorni fa e non c’è nessuna pull request aperta. Aperta
software-challenge/backend#428 · 1 assegnatario ·
-
Convert XStreamClient to KotlinForse di nuovo libera @xeruf l’ha presa 1064 giorni fa e non c’è nessuna pull request aperta. Apertaaction:rework
software-challenge/backend#423 · 1 assegnatario ·
-
Add a licenseAperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 35/100
software-challenge/backend#422 ·
-
action:implement component:build
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
software-challenge/backend#401 · 1 commento ·
-
Gradle deploy task does not detect version change appropriatelyForse di nuovo libera @xeruf l’ha presa 2092 giorni fa e non c’è nessuna pull request aperta. Apertacomponent:build
software-challenge/backend#387 · 1 assegnatario ·
Tutte le issue di software-challenge/backend
Issue simili
-
auto:producer auto:security
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
fritzprix/libr-agent#2595 ·
I maintainer di solito rispondono entro 1 giorno
-
Non-root first start logs "Base venv updated (stamp mismatch)" instead of the first-run messageApertaarea: infrastructure bug priority: low
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
snapotter-hq/SnapOtter#4573 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 83/100
-
comp: ssr comp: zones type: feature version: current (v17+)
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
angular/angularfire#3836 ·
I maintainer di solito rispondono entro 3 giorni