• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

d00rman / restbase / 184
88%
master: 84%

Build:
Build:
LAST BUILD BRANCH: parsoidproxy/mirror-html2html
DEFAULT BRANCH: master
Ran 17 Sep 2015 11:53AM UTC
Jobs 2
Files 15
Run time 8s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
184

push

travis-ci

d00rman
Mathoid: Add public and back-end endpoints

This commit adds two public routes:

- `POST /{domain}/media/math`
- `GET /{domain}/media/math/{hash}`

The first allows clients to perform a POST request to ask for a formula
to be rendered. It takes the same parameters as Mathoid, namely `q` (the
formula to be rendered), `type` (the format or type of the supplied
formula) and `format` (the desired output format). Only `q` is
mandatory, `type` defaults to `tex`, while `format` is presumed to be
`json` if not supplied. Internally, the request is saved using the
*post_data* module. The request hash is therefore calculated and is used
to determine if the given formula has already been rendered by Mathoid
in the sought output format. If so, the stored version is returned.
Otherwise, a request is issued to Mathoid and its result is stored and
returned. In either case, the response contains the `x-resource-location`
header which can be used to perform subsequent, low-latency requests to
obtain the same render via the second public endpoint.

Note that the endpoints and their storage are organised in such a way as
to be domain-independent. This commit introduces a new, global domain -
`window.wikimedia.org` - and all Mathoid requests are internally
remapped to it. In other words, if a render with the data hash `12345`
exists, it can be retrieved equally from all domains, regardless of the
initial request's domain.

Also, this commit reorganises slightly the configuration files.

1500 of 1699 relevant lines covered (88.29%)

335.44 hits per line

Jobs
ID Job ID Ran Files Coverage
1 184.1 17 Sep 2015 11:53AM UTC 0
88.29
Travis Job 184.1
3 184.3 17 Sep 2015 11:53AM UTC 0
88.29
Travis Job 184.3
Source Files on build 184
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #184
  • dd510452 on github
  • Prev Build on mathoid/post-routes (#183)
  • Next Build on mathoid/post-routes (#185)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc