Giter Site home page Giter Site logo

table-state-rest-api's Introduction

Table Component REST API

Data has to be obtained and processed before displaying it on the Table Component (https://github.com/clarity-h2020/table-components). This REST API is meant to provide a simple way of retrieving the data stored on the geoserver instance and returning the appropriate information to the Table Component.

For more information check the discussion on issues: clarity-h2020/table-components#1 clarity-h2020/table-components#3

Dependencies:

  • Python 3.5 or higher
  • numpy 1.13.3 or higher
  • OWSLib 0.17.1 or higher
  • GDAL 2.1.3 or higher
  • Flask 0.12.2 or higher

Samples

Sample JSON request and response files can be found on the examples folder.

table-state-rest-api's People

Contributors

ghilbrae avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

table-state-rest-api's Issues

Test the current version of the API

@therter I have just finished configuring the service. It can be found here:

https://clarity.meteogrid.com/api/request_exposure
https://clarity.meteogrid.com/api/request_hazard

There are only two options for now. To make it work you need to do a POST request with a certain request.json file depending on the request. You can find the examples in the examples folder: https://github.com/clarity-h2020/table-state-rest-api/tree/master/examples

I've been using the layers already available in geoserver. I'm keeping in mind what @maesbri said about a different source in the future, but I won't implement it until I have some feedback.

Note that the requests are very sensible to the bbox. I'm working on some error handling on that regard and on other possible sources of error now, but it's not yet available in the server.

The responses should look something like what you see in the same folder.

Exposure - Switch to EMIKAT API

Exposure Data (Population) for whole Europe will be served from a new EMIKAT API.
This means, that the table API for aggregating Exposure Data has to be updated accordingly.
Additionally, the respective Exposure Resources in the Data Package have to be updated as well as the Table Component.

@humerh Could you please provide an example request and response? To keep the changes to the table-state-rest-api minimal, it would be helpful if EMIKAT API could offer the the same API as currently used by the table-state-rest-api to access the underlying exposure data. @ghilbrae Is it WCS, WFS, ...?

It may be necessary to parametrise the URL as described here. Likewise the parameters have to be supported by the table-state-rest-api. This is somehow related to #3.

Update server with new version

@therter I have a newer version of the API ready but I did not want to update anything on our server just before the review.

This new version has some exception control and logging capabilities, which should not be a problem from your side. But also, I've added an EPSG field to the requests, which you'll need to consider. I'd rather you let me know when it is best for you to do this change so it does not mess up anything you might be working on.

Submit layer URLs within the request

It may be needed to add a URL field to the request to determine the source of the layer.

There are a few considerations:

  • All the layers of one request are stored in the same source (geoserver or whatever) => one global field in the request.
  • Each layer is retrieved from a different source => a field per layer.
  • The layers will always come from the same source => no need for field, handle this via API configuration.

Units for Hazard table

It may be needed to add unit information to the responses for the HC layers.

The existing layers do not have that information as of now. This should be taken into account in the future to add this when generating the layers.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.