Thanks for the information, Karl.

I have a couple more questions:

It looks like the format is being applied in cases where ordering might not really matter, e.g. listing jobs as in the example I gave. (Or perhaps order does matter here?)

Is there any more doc on the non-sugared format than the examples in the table at https://manifoldcf.apache.org/release/release-2.12/en_US/programmatic-operation.html#JSON+equivalents+for+ManifoldCF

Is there something I can do in my requests to get the sugared format for cases where I don't care about ordering?

Cheers,
James


On  2019-01-17 09:34 Karl Wright said:
The output format did change, and the reason was because the "syntactic sugar" format would not preserve ordering, so that if you output and re-input, you'd lose information.

The more complex form is being used only where there is a possibility of ordering confusion.  It was always accepted as input (so that has not changed).

Thanks,
Karl


On Thu, Jan 17, 2019 at 1:44 AM James Thomas <james.thomas@linguamatics.com> wrote:
Hi,

After installing MCF 2.12 I am seeing a change in the JSON response format from the REST API.

Here's an example, from the URL mcf-api-service/json/jobs. I've isolated a job which exists in both my 2.11 and 2.12 instances. 2.11 is on the left:



The 2.12 format feels "internal" and I see that https://manifoldcf.apache.org/release/release-2.12/api/framework/constant-values.html shows e.g. "_type_", "_children_" as constants (but that's also true in 2.12.

I can't see a release note that talks about this change, although "CONNECTORS-1549: Problem with API output JSON: losing order in child records." talks about JSON format and the test data for that change (https://issues.apache.org/jira/secure/attachment/12944641/CONNECTORS-1549.patch) appears to change the JSON format as in my observation.

Is this change expected, and if so is there a way to request the pre-2.12 format?

Cheers,
James


--
James Thomas
Head of Testing
Linguamatics
Phone: +44 (0)1223 651910 |
Website: www.linguamatics.com |
Address: 324 Cambridge Science Park | Milton Road | Cambridge, UK | CB4 0WG
LinkedIn | Twitter | Facebook
Frost & Sullivan Best Practices Award 2016 & 2017 |
Queen's Award for Enterprise: International Trade 2014
Linguamatics Limited is a company incorporated in England and Wales with registered number: 4248841
and a registered office at 324 Cambridge Science Park, Milton Road, Cambridge, CB4 0WG

 

James Thomas
Head of Testing
Linguamatics
Phone: +44 (0)1223 651910 |
Website: www.linguamatics.com |
Address: 324 Cambridge Science Park | Milton Road | Cambridge, UK | CB4 0WG
LinkedIn | Twitter | Facebook
Frost & Sullivan Best Practices Award 2016 & 2017 |
Queen's Award for Enterprise: International Trade 2014
Linguamatics Limited is a company incorporated in England and Wales with registered number: 4248841
and a registered office at 324 Cambridge Science Park, Milton Road, Cambridge, CB4 0WG