Coder Social home page Coder Social logo

nfservice's Introduction

nfservice

A sample to demonstrate a basic network functions communication. There are two network functions here NF1 and NF2 which have REST based interfaces. NF1 exposes an API to get the url of NF2 api.

Both NF1 and NF2 have an inbuilt http server and http client. NF1 exposes an a REST API /nf2loc to get the location of the NF2.

  • On query(GET request) from the client to NF1 [client -> GET (http://localhost:8060/nf2loc) -> NF1]
  • NF1 sends a POST request to NF2 with the api location of NF1 in the body and the time when the request has been sent [ NF1 -> POST (http://localhost:8090/) -> NF2 ]
  • NF2 on receiving the POST request from NF1, NF2 checks the content of the request, if proper responds with a 200 OK. [ NF2 -> 200 OK(POST) -> NF1 ]
  • NF2 sends a POST request to NF1 with the api location of NF2 in the body and the time when the request has been sent [ NF2 -> POST (http://localhost:8070) -> NF1]
  • NF1 on receiving the POST request from NF2, NF1 checks the content of the request, if proper responds with a 200 OK. [NF1 -> 200 OK(POST) -> NF2 ]
  • NF1 responds to the GET request from the client with the location of NF2 and the time when the NF2 had generated the request.[NF1 -> 200 OK(GET) -> client]

NF1

Configurations of NF1 are as below which is provided in JSON format

remotenfapiroot : API root of the NF2. The NF1 uses the API root to query the NF2 api location. default: http://localhost:8090"

localapirootprefix : API root prefix of the NF1. The NF1 uses the API root prefix to sends its api location towards NF2. default:http://localhost

HTTPConfig

apiendpoint : The end point of the NF1 for the API from the client. default::8060

nfendpoint : The end point of the NF1 server for requests from NF2. default: :8070

NF2

Configurations of NF2 are as below which is provided in JSON format

localapirootprefix : API root prefix of the NF2. The NF2 uses the API root prefix to sends its api location towards NF1. default:http://localhost

nfendpoint : The end point of the NF2 server for requests from NF1. default: :8090

Screenshot of a successful execution

NF_Screeshot

nfservice's People

Contributors

abjyoti avatar sudhir-intc avatar

Watchers

 avatar

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.