Eureka with Node-Js client registration succeed but heartbeat failed(always re-register)











up vote
0
down vote

favorite












I have an eureka server with multiple clients, one of them is nodejs ,
all the java clients work as expected but the nodejs gives the following errors:



retrieved full registry successfully
registered with eureka: dbServer/dbServer
eureka heartbeat FAILED, Re-registering app
retrieved full registry successfully
registered with eureka: dbServer/dbServer
eureka heartbeat FAILED, Re-registering app
...


In the eureka server on the other hand I can see the following:



DS: Registry: lease doesn't exist, , registering resource: DBSERVER - dbServer 
Not Found (Renew): DBSERVER - dbServer
Registered instance DBSERVER/DBSERVER with status UP (replication=false)
Registered instance DBSERVER/DBSERVER with status UP (replication=true)
DS: Registry: lease doesn't exist, registering resource: DBSERVER - dbServer
Not Found (Renew): DBSERVER - dbServer
...


The client configuration(Node js):



const client = new Eureka({
// application instance information
instance: {
app: 'dbServer',
instanceId: 'dbServer',
hostName: 'localhost',
ipAddr: '127.0.0.1',
port: {
'$': port,
'@enabled': 'true',
},
vipAddress: 'dbServer',
dataCenterInfo: {
'@class': 'com.netflix.appinfo.InstanceInfo$DefaultDataCenterInfo',
name: 'MyOwn',
},
registerWithEureka: true,
fetchRegistry: true
},
eureka: {
// eureka server host / port
host: 'localhost',
port: 8761,
servicePath: '/eureka/apps',
},
});

client.logger.level('debug');
client.start((error) => {
console.log(error || 'complete');
});


Does anyone has a solution to this issue? it the commands still manage to arrive to the client but the logs are filled ,
Many thanks










share|improve this question




























    up vote
    0
    down vote

    favorite












    I have an eureka server with multiple clients, one of them is nodejs ,
    all the java clients work as expected but the nodejs gives the following errors:



    retrieved full registry successfully
    registered with eureka: dbServer/dbServer
    eureka heartbeat FAILED, Re-registering app
    retrieved full registry successfully
    registered with eureka: dbServer/dbServer
    eureka heartbeat FAILED, Re-registering app
    ...


    In the eureka server on the other hand I can see the following:



    DS: Registry: lease doesn't exist, , registering resource: DBSERVER - dbServer 
    Not Found (Renew): DBSERVER - dbServer
    Registered instance DBSERVER/DBSERVER with status UP (replication=false)
    Registered instance DBSERVER/DBSERVER with status UP (replication=true)
    DS: Registry: lease doesn't exist, registering resource: DBSERVER - dbServer
    Not Found (Renew): DBSERVER - dbServer
    ...


    The client configuration(Node js):



    const client = new Eureka({
    // application instance information
    instance: {
    app: 'dbServer',
    instanceId: 'dbServer',
    hostName: 'localhost',
    ipAddr: '127.0.0.1',
    port: {
    '$': port,
    '@enabled': 'true',
    },
    vipAddress: 'dbServer',
    dataCenterInfo: {
    '@class': 'com.netflix.appinfo.InstanceInfo$DefaultDataCenterInfo',
    name: 'MyOwn',
    },
    registerWithEureka: true,
    fetchRegistry: true
    },
    eureka: {
    // eureka server host / port
    host: 'localhost',
    port: 8761,
    servicePath: '/eureka/apps',
    },
    });

    client.logger.level('debug');
    client.start((error) => {
    console.log(error || 'complete');
    });


    Does anyone has a solution to this issue? it the commands still manage to arrive to the client but the logs are filled ,
    Many thanks










    share|improve this question


























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I have an eureka server with multiple clients, one of them is nodejs ,
      all the java clients work as expected but the nodejs gives the following errors:



      retrieved full registry successfully
      registered with eureka: dbServer/dbServer
      eureka heartbeat FAILED, Re-registering app
      retrieved full registry successfully
      registered with eureka: dbServer/dbServer
      eureka heartbeat FAILED, Re-registering app
      ...


      In the eureka server on the other hand I can see the following:



      DS: Registry: lease doesn't exist, , registering resource: DBSERVER - dbServer 
      Not Found (Renew): DBSERVER - dbServer
      Registered instance DBSERVER/DBSERVER with status UP (replication=false)
      Registered instance DBSERVER/DBSERVER with status UP (replication=true)
      DS: Registry: lease doesn't exist, registering resource: DBSERVER - dbServer
      Not Found (Renew): DBSERVER - dbServer
      ...


      The client configuration(Node js):



      const client = new Eureka({
      // application instance information
      instance: {
      app: 'dbServer',
      instanceId: 'dbServer',
      hostName: 'localhost',
      ipAddr: '127.0.0.1',
      port: {
      '$': port,
      '@enabled': 'true',
      },
      vipAddress: 'dbServer',
      dataCenterInfo: {
      '@class': 'com.netflix.appinfo.InstanceInfo$DefaultDataCenterInfo',
      name: 'MyOwn',
      },
      registerWithEureka: true,
      fetchRegistry: true
      },
      eureka: {
      // eureka server host / port
      host: 'localhost',
      port: 8761,
      servicePath: '/eureka/apps',
      },
      });

      client.logger.level('debug');
      client.start((error) => {
      console.log(error || 'complete');
      });


      Does anyone has a solution to this issue? it the commands still manage to arrive to the client but the logs are filled ,
      Many thanks










      share|improve this question















      I have an eureka server with multiple clients, one of them is nodejs ,
      all the java clients work as expected but the nodejs gives the following errors:



      retrieved full registry successfully
      registered with eureka: dbServer/dbServer
      eureka heartbeat FAILED, Re-registering app
      retrieved full registry successfully
      registered with eureka: dbServer/dbServer
      eureka heartbeat FAILED, Re-registering app
      ...


      In the eureka server on the other hand I can see the following:



      DS: Registry: lease doesn't exist, , registering resource: DBSERVER - dbServer 
      Not Found (Renew): DBSERVER - dbServer
      Registered instance DBSERVER/DBSERVER with status UP (replication=false)
      Registered instance DBSERVER/DBSERVER with status UP (replication=true)
      DS: Registry: lease doesn't exist, registering resource: DBSERVER - dbServer
      Not Found (Renew): DBSERVER - dbServer
      ...


      The client configuration(Node js):



      const client = new Eureka({
      // application instance information
      instance: {
      app: 'dbServer',
      instanceId: 'dbServer',
      hostName: 'localhost',
      ipAddr: '127.0.0.1',
      port: {
      '$': port,
      '@enabled': 'true',
      },
      vipAddress: 'dbServer',
      dataCenterInfo: {
      '@class': 'com.netflix.appinfo.InstanceInfo$DefaultDataCenterInfo',
      name: 'MyOwn',
      },
      registerWithEureka: true,
      fetchRegistry: true
      },
      eureka: {
      // eureka server host / port
      host: 'localhost',
      port: 8761,
      servicePath: '/eureka/apps',
      },
      });

      client.logger.level('debug');
      client.start((error) => {
      console.log(error || 'complete');
      });


      Does anyone has a solution to this issue? it the commands still manage to arrive to the client but the logs are filled ,
      Many thanks







      node.js netflix-eureka






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Nov 7 at 17:04









      spencergibb

      12.5k22847




      12.5k22847










      asked Nov 7 at 15:40









      Roie Beck

      307




      307
























          1 Answer
          1






          active

          oldest

          votes

















          up vote
          0
          down vote



          accepted










          PSo the answer is simple,



               instance: {
          app: 'dbServer',
          instanceId: 'dbServer',


          InstanceId and app name cannot be identical.



          Changeing any one will solve this issue.






          share|improve this answer





















            Your Answer






            StackExchange.ifUsing("editor", function () {
            StackExchange.using("externalEditor", function () {
            StackExchange.using("snippets", function () {
            StackExchange.snippets.init();
            });
            });
            }, "code-snippets");

            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "1"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














             

            draft saved


            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53192789%2feureka-with-node-js-client-registration-succeed-but-heartbeat-failedalways-re-r%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            0
            down vote



            accepted










            PSo the answer is simple,



                 instance: {
            app: 'dbServer',
            instanceId: 'dbServer',


            InstanceId and app name cannot be identical.



            Changeing any one will solve this issue.






            share|improve this answer

























              up vote
              0
              down vote



              accepted










              PSo the answer is simple,



                   instance: {
              app: 'dbServer',
              instanceId: 'dbServer',


              InstanceId and app name cannot be identical.



              Changeing any one will solve this issue.






              share|improve this answer























                up vote
                0
                down vote



                accepted







                up vote
                0
                down vote



                accepted






                PSo the answer is simple,



                     instance: {
                app: 'dbServer',
                instanceId: 'dbServer',


                InstanceId and app name cannot be identical.



                Changeing any one will solve this issue.






                share|improve this answer












                PSo the answer is simple,



                     instance: {
                app: 'dbServer',
                instanceId: 'dbServer',


                InstanceId and app name cannot be identical.



                Changeing any one will solve this issue.







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Nov 7 at 19:00









                Roie Beck

                307




                307






























                     

                    draft saved


                    draft discarded



















































                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53192789%2feureka-with-node-js-client-registration-succeed-but-heartbeat-failedalways-re-r%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    這個網誌中的熱門文章

                    Tangent Lines Diagram Along Smooth Curve

                    Yusuf al-Mu'taman ibn Hud

                    Zucchini