Skip to content

Dr0na/eva-projects-service

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

eva-projects-service

This repository hosts a Spring Boot based ReSTful service implementation for listing genome sequencing and variation study projects at EMBL. The service allows fetching information by project id alongwith searching projects on taxonomy common name.

It uses an volatile in-mem H2 database. The data is lost on application shutdown. It is automatically loaded back on application startup from data.sql file. The database implementation could be changed if desired with no change in code.

Features

  1. Support for listing project by Id
  2. Support for listing of all projects
  3. Support for case-Insensitive filtering on taxonomy common name
  4. Support for sorting of results on multiple output attributes with the default order
  5. Support for pagination of output
  6. Support for defining output page size

API Endpoints

The OpenAPI documentation can be accessed at this link.

Method URI Query params Response Codes
GET /api/1.0/projects
  • taxonomyCommonName (string) - taxonomy common name. Value can be case-insensitive.
  • page (integer) - Zero based page number
  • size (integer) - items to list in the page
  • sort (string) - comma separated list of attributes to sort the output on
  • 200.
GET /api/1.0/projects/{projectId} None
  • 200 - when matching resource(s) is found.
  • 404 - when no matching resource(s) is found.

Usage examples

  1. List project with id 'PRJEB629'
  2. List all projects
  3. Filter and list projects matching a taxonomy
  4. Filter and list single page of projects
  5. Filter and list single page of projects with custom page size
  6. Filter and list single page of projects with custom page size sorted on a single attribute
  7. Filter and list single page of projects with custom page size sorted on a multiple attributes

Dependencies

  1. Spring Data JPA - For JPA implementation
  2. Spring Web - For building RESTful interface using Spring MVC
  3. springdoc-openapi - For OpenApi document generation
  4. Lombok - For auto-generation of code
  5. specification-arg-resolver - An alternative API for filtering data with Spring MVC and Spring Data JPA

About

EVA Projects Service for genome project information.

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages