Giter Site home page Giter Site logo

/ping endpoint about tng-sdk-descriptorgen HOT 8 CLOSED

sonata-nfv avatar sonata-nfv commented on September 26, 2024
/ping endpoint

from tng-sdk-descriptorgen.

Comments (8)

felipevicens avatar felipevicens commented on September 26, 2024 1

Hello @StefanUPB

In nginx, would be enough to add this to the default site:

location /ping {
    return 200 '{'ping': 'pong'}';
    add_header Content-Type application/json;
}

Or even:

location /ping {
    return 200 ':-)';
    add_header Content-Type text/plain;
}

from tng-sdk-descriptorgen.

jbonnet avatar jbonnet commented on September 26, 2024

@StefanUPB
Please mind that the returned status really reflects the component status, i.e., imagine the nginx is running hapilly without knowing the actual requests to the component are failling...

from tng-sdk-descriptorgen.

stefanbschneider avatar stefanbschneider commented on September 26, 2024

You're right. I guess it should somehow check if the GUI is accessible before sending the response. I'll have to think about how to do this. Do you have any suggestions?

from tng-sdk-descriptorgen.

jbonnet avatar jbonnet commented on September 26, 2024

@felipevicens
But what happens when the nginx is in a container and the service is in another? Does nginx already checks this with the configured upstreams?

from tng-sdk-descriptorgen.

stefanbschneider avatar stefanbschneider commented on September 26, 2024

Maybe what Felipe is suggesting is enough. After all, the descriptorgen is just a web-based GUI served by a web server (e.g., nginx). Users go to the container's IP to access the GUI and use the descriptorgen. So if nginx is running, the descriptorgen GUI should be accessible.

So far, there are no direct interactions with other components.

from tng-sdk-descriptorgen.

felipevicens avatar felipevicens commented on September 26, 2024

@jbonnet this nginx serve static files. I think is enough for "tng-sdk-descriptorgen"

In case of others repo, the answer is yes, we will need mechanisms to check the backend.

from tng-sdk-descriptorgen.

jbonnet avatar jbonnet commented on September 26, 2024

:-) fine on me

from tng-sdk-descriptorgen.

efotopoulou avatar efotopoulou commented on September 26, 2024

@jbonnet @StefanUPB
My point of view, (maybe is too simplistic) is totally in line with @felipevicens . I do not think there is any need for an extra web server per component. Each component (ex.tng-policy-mngr) should support the /ping API. tng-devops component knows all registred components from sdk,V&V and sp , so maybe an extra test there could gather the 200 HTTP responses or report the failed interactions.

from tng-sdk-descriptorgen.

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.