GithubHelp home page GithubHelp logo

Comments (8)

shahsank3t avatar shahsank3t commented on May 30, 2024

@nextropia - Thanks for pointing out the performance issue.

@satishd - We might need to make some API modification for UI to get all the schema information, with its metadata and version in a single API request.

Currently, we are hitting following requests:

  1. schemas - to get all the schema
  2. schemas/:schemaName - to get metadata for ":schemaName" (We hit this API for as many schema's present)
  3. schemas/:schemaName/versions - to get all version for ":schemaName" (We hit this API for as many schema's present)

Assuming, we have 5 schemas, UI is making 11 API calls which get's on increasing.

Can we have another simple GET ALL API that gathers all this data in the backend for all schema present and return the complete response?
It should reduce a significant amount of time I guess.

cc: @harshach - What do you think?

I'll also fix the initial "No data found" and show loading indication.

from registry.

satishd avatar satishd commented on May 30, 2024

@shahsank3t I think we should not get all the data in one api call which may be heavy and unnecessary. We can get schemas with basic metadata without versions.

Multiple ways to fetch individual schema versions

  • Respective schema versions can be fetched when user clicks on any particular schema.
  • Get schema versions which are visible within the window. We can have new api to get versions of given schemas.

All this data can be cached locally as this is not going to be modified.

from registry.

shahsank3t avatar shahsank3t commented on May 30, 2024

@satishd Sure, having a 2 API's (Schema + metadata & Version separate) will work.

I think adding "id", "timestamp" & "versionCount" for every schema metadata and fixing "description" which is also set to null for "schemas" API, should be the only change needed from the backend.

from registry.

harshach avatar harshach commented on May 30, 2024

@shahsank3t how about we display the metadata first and upon clicking to expand the schema we make a call to fetch the schema text?

from registry.

shahsank3t avatar shahsank3t commented on May 30, 2024

@harshach yup that's the plan now. Once we have the changes I mentioned in my previous comment, I'll do rest of the changes on the UI.

from registry.

andrew-rosca avatar andrew-rosca commented on May 30, 2024

from registry.

satishd avatar satishd commented on May 30, 2024

Discussed with @shahsank3t, no need to add any backend apis and existing apis are sufficient to resolve the issue.

from registry.

shahsank3t avatar shahsank3t commented on May 30, 2024

PR #75 is raised for this issue.

from registry.

Related Issues (20)

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.