@everymundo/resilient-eureka

    0.1.0 • Public • Published

    resilient-eureka

    resilient.js middleware for Netflix Eureka discovery service

    Installation

    npm install resilient-eureka --save
    

    Usage

    const Resilient = require('resilient')
    const eurekaMiddleware = require('resilient-eureka')
    
    const client = Resilient()
    
    //eureka urls
    const servers = [
      'http://demo.eureka.com'
    ]
    
    client.use(eurekaMiddleware({
      serviceName: 'service'
    }))
    
    client.discoveryServers(servers)
    
    // Test request
    client.get('/', function (err, res) {
      if (res.status === 200) {
        console.log('Response:', res)
      }
    })

    Params

    • serviceName/serviceVipAddress string - name/vipAddress of service registered in Eureka (one of these is required)
    • path string - path to query for all Eureka's services instances (default: /eureka/apps)
    • protocol string - transport protocol (default: http)

    Install

    npm i @everymundo/resilient-eureka

    DownloadsWeekly Downloads

    4

    Version

    0.1.0

    License

    MIT

    Unpacked Size

    5.21 kB

    Total Files

    5

    Last publish

    Collaborators

    • alex-orga
    • vladimirpetrov
    • estebanpablo89
    • yartiles
    • jonmorazav
    • emdavidmoreno
    • everymundo-admin
    • ballester
    • danielsan
    • halain
    • avivero93
    • anahiem
    • herlin
    • karinfdez
    • ernestocarrasco
    • erlin
    • front10devs
    • hdelcastillo
    • dcuevacem
    • rodneyem
    • ortega.dc98
    • pedroleon917
    • kaylingw
    • joeaspiazuem
    • lazjramos
    • daniuska-em
    • cstansfld