Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
Genesys Backend
Genesys Backend
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 44
    • Issues 44
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Operations
    • Operations
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
  • Genesys PGR
  • Genesys BackendGenesys Backend
  • Issues
  • #330

Closed
Open
Opened Sep 14, 2018 by Matija Obreza@mobrezaOwner
  • Report abuse
  • New issue
Report abuse New issue

ApiInfoController v1

Implement a new ApiInfoController v1 at public static final String CONTROLLER_URL = ApiBaseController.APIv1_BASE + "/info"; in the server.api.v1 package.

Copy info method from existing ApiInfoController (from Catalog)

Extra data

Add additional properties to the returned object:

  • String[] cdnServers loaded from application.properties (see genesys-pgr/genesys-server/issues/328)
  • long accessionCount number of all accessions from accessionService.count()
  • long datasetCount number of published datasets
  • long subsetCount number of published subsets
  • long instituteCount number of institutes with accessions in Genesys
  • long descriptorCount number of published descriptors
  • long partnerCount number of Partners

Implementation

Please implement these "count" methods when they are missing and use this template (when possible):

@Override
public long countAccessions(AccessionFilter filter) {
	long total = elasticsearchService.count(Accession.class, filter);

	if (total < 10000) {
		// If total is below 10K, use actual count
		total = accessionRepository.count(filter.buildQuery());
	}
	
	return total;
}

Extras

Also expose:

  • captchaSiteKey as captchaSiteKey
  • google.analytics.account as googleAnalyticsId
  • itpgrfa.glis.basepath as glisUrl
Edited Sep 18, 2018 by Matija Obreza
Assignee
Assign to
2.4
Milestone
2.4 (Past due)
Assign milestone
Time tracking
None
Due date
None
Reference: genesys-pgr/genesys-server#330