Page MenuHomePhabricator

Add /list/pair/{from}/{to}, /list/tool/{tool} and /list/languagepairs in the CXServer API
Closed, ResolvedPublic

Description

Implement the changes in the API on the CXServer side.

Add following API end points:

  • /list/tool/{tool}
  • /list/pair/{from}/{to}
  • /list/languagepairs

Details

Related Gerrit Patches:
mediawiki/services/cxserver : masterRemove /languagepairs in favour of /list/languagepairs
mediawiki/extensions/ContentTranslation : masterSource selector: Use /list/languagepairs api of cxserver
mediawiki/services/cxserver : masterAdd /list/languagepairs API end point
mediawiki/services/cxserver : masterAdd /list/pair/{from}/{to} end point
mediawiki/services/cxserver : masterAdd /list/tool/{tool} API end point

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

We also need /list/tool/{tool} which can be achieved with the current /list/{tool}{/from}{/to} endpoint without supplying from and to.

mobrovac renamed this task from Add /list/pair/{from}/{to} and /list/languagepairs in the CXServer API to Add /list/pair/{from}/{to}, /list/tool/{tool} and /list/languagepairs in the CXServer API.Apr 13 2017, 8:03 PM
mobrovac updated the task description. (Show Details)

We also need /list/tool/{tool} which can be achieved with the current /list/{tool}{/from}{/to} endpoint without supplying from and to.

We've /list/mt too!

Change 348428 had a related patch set uploaded (by KartikMistry):
[mediawiki/services/cxserver@master] Rename end point /list/{tool} to /list/tools/{tool}

https://gerrit.wikimedia.org/r/348428

Change 348441 had a related patch set uploaded (by KartikMistry):
[mediawiki/services/cxserver@master] WIP: Rename /languagepairs to /list/languagepairs

https://gerrit.wikimedia.org/r/348441

@mobrovac /list/{tool}{/from}{/to} returns available tools for a given language pair. Is same as we want to achieve via /list/pair{/from}{/to}?

@mobrovac /list/{tool}{/from}{/to} returns available tools for a given language pair. Is same as we want to achieve via /list/pair{/from}{/to}?

Euh, no it's not the same. For /list/{tool}{/from}{/to} you have to supply the tool, what we want is the inverse: given a language pair what are the tools available for it.

@mobrovac /list/{tool}{/from}{/to} returns available tools for a given language pair. Is same as we want to achieve via /list/pair{/from}{/to}?

Euh, no it's not the same. For /list/{tool}{/from}{/to} you have to supply the tool, what we want is the inverse: given a language pair what are the tools available for it.

Thanks. Clear now.

Change 348492 had a related patch set uploaded (by KartikMistry):
[mediawiki/services/cxserver@master] WIP: Add /list/pair/{from}/{to} end point

https://gerrit.wikimedia.org/r/348492

Status:

  • Patches in review, but need more testing and some work as per Marko's comments.

Change 348428 merged by jenkins-bot:
[mediawiki/services/cxserver@master] Add /list/tool/{tool} API end point

https://gerrit.wikimedia.org/r/348428

Change 348492 merged by Ppchelko:
[mediawiki/services/cxserver@master] Add /list/pair/{from}/{to} end point

https://gerrit.wikimedia.org/r/348492

Change 348441 merged by Ppchelko:
[mediawiki/services/cxserver@master] Add /list/languagepairs API end point

https://gerrit.wikimedia.org/r/348441

Change 374506 had a related patch set uploaded (by Santhosh; owner: Santhosh):
[mediawiki/extensions/ContentTranslation@master] Source selector: Use /list/languagepairs api of cxserver

https://gerrit.wikimedia.org/r/374506

Change 374508 had a related patch set uploaded (by Santhosh; owner: Santhosh):
[mediawiki/services/cxserver@master] Remove /languagepairs in favour of /list/languagepairs

https://gerrit.wikimedia.org/r/374508

santhosh closed this task as Resolved.Aug 29 2017, 9:22 AM

Change 374506 merged by jenkins-bot:
[mediawiki/extensions/ContentTranslation@master] Source selector: Use /list/languagepairs api of cxserver

https://gerrit.wikimedia.org/r/374506

Change 374508 merged by jenkins-bot:
[mediawiki/services/cxserver@master] Remove /languagepairs in favour of /list/languagepairs

https://gerrit.wikimedia.org/r/374508