Bug 483195 - Refactor MPC Core REST implementation
Summary: Refactor MPC Core REST implementation
Status: NEW
Alias: None
Product: MPC
Classification: Technology
Component: Install (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 1.5.1   Edit
Assignee: Carsten Reckord CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 484512 484514 484513
Blocks:
  Show dependency tree
 
Reported: 2015-11-27 13:44 EST by Carsten Reckord CLA
Modified: 2016-06-07 12:29 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Carsten Reckord CLA 2015-11-27 13:44:15 EST
MPC's implementation of the Marketplace REST interface currently revolves around a hand-crafted XML parser, a POJO data model and a transport layer backed by P2. This is an umbrella bug to clean up and refactor this implementation to solve some technical debt and make future development easier.

Especially the XML parser hasn't aged particularly well. Every change to the REST interface and data model requires multiple careful and consistent changes in the parser. There are better alternatives around, starting with JAXB and not ending with EMF. We should modernize this layer while keeping the data model API unchanged [*].

The other area of concern is MPC's use of P2 as its network transport layer. The way we are using it, P2 just adds one more layer on top of ECF and Apache HTTP client without much additional benefit. The problem with this approach is that it doesn't give us much control over the HTTP communication and cuts us off from many of the available options. E.g. we currently use HTTP client directly for install reports, because POST access is not possible through the P2 layer. Also, controlling retries and timeouts (bug 461104), setting referers or user agents (bug 317339) or requesting gzipped content (bug 314938) is not possible.


---
[*] But we could use the opportunity to clean up some of the data model, like deprecating multivalue classes like IIus and ICategories and using proper data types for URIs etc instead of just strings.
Comment 1 Carsten Reckord CLA 2016-06-07 12:29:08 EDT
Moving to 1.5.1 for the remaining cleanup and XML parser work.