Spring-boot Application Throwing Error on Actuator Port





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}







1















In my Java application, I have kept the server port at: 8090
And the property management.port=9080



Now, in my browser, when I open a random link (http://localhost:9080) on the actuator port, my application throws the following error:




No mapping found for HTTP request with URI [/] in DispatcherServlet with name 'dispatcherServlet'
23/11/2018:18:47:54.350 [http-nio-9080-exec-1] E o.a.c.c.C.[.[.[.[dispatcherServlet] --- Servlet.service() for servlet [dispatcherServlet] threw exception
java.lang.IllegalArgumentException: No converter found for return value of type: class java.util.LinkedHashMap




Whereas, when I put management.port=8090 (same as the server port), this error is not thrown when I open a random link.



Is there a way to add a default request handler on the actuator port when it is different from the server port in a spring boot application?










share|improve this question

























  • Can you show your pom.xml?

    – Sukhpal Singh
    Nov 23 '18 at 15:03











  • I'm not sure I can do that, but could you tell me what you're looking for? I have added the jackson dependency.

    – Rishabh Sanghi
    Nov 23 '18 at 17:22











  • Your spring-boot version and jackson dependency which you just confirmed is there.

    – Sukhpal Singh
    Nov 23 '18 at 17:23











  • <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>1.5.10.RELEASE</version> <relativePath/> <!-- lookup parent from repository --> </parent>

    – Rishabh Sanghi
    Nov 23 '18 at 18:39













  • See Add DefaultHandlerExceptionResolver to child context. Try upgrading to 1.5.16.RELEASE

    – Sukhpal Singh
    Nov 24 '18 at 7:29


















1















In my Java application, I have kept the server port at: 8090
And the property management.port=9080



Now, in my browser, when I open a random link (http://localhost:9080) on the actuator port, my application throws the following error:




No mapping found for HTTP request with URI [/] in DispatcherServlet with name 'dispatcherServlet'
23/11/2018:18:47:54.350 [http-nio-9080-exec-1] E o.a.c.c.C.[.[.[.[dispatcherServlet] --- Servlet.service() for servlet [dispatcherServlet] threw exception
java.lang.IllegalArgumentException: No converter found for return value of type: class java.util.LinkedHashMap




Whereas, when I put management.port=8090 (same as the server port), this error is not thrown when I open a random link.



Is there a way to add a default request handler on the actuator port when it is different from the server port in a spring boot application?










share|improve this question

























  • Can you show your pom.xml?

    – Sukhpal Singh
    Nov 23 '18 at 15:03











  • I'm not sure I can do that, but could you tell me what you're looking for? I have added the jackson dependency.

    – Rishabh Sanghi
    Nov 23 '18 at 17:22











  • Your spring-boot version and jackson dependency which you just confirmed is there.

    – Sukhpal Singh
    Nov 23 '18 at 17:23











  • <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>1.5.10.RELEASE</version> <relativePath/> <!-- lookup parent from repository --> </parent>

    – Rishabh Sanghi
    Nov 23 '18 at 18:39













  • See Add DefaultHandlerExceptionResolver to child context. Try upgrading to 1.5.16.RELEASE

    – Sukhpal Singh
    Nov 24 '18 at 7:29














1












1








1








In my Java application, I have kept the server port at: 8090
And the property management.port=9080



Now, in my browser, when I open a random link (http://localhost:9080) on the actuator port, my application throws the following error:




No mapping found for HTTP request with URI [/] in DispatcherServlet with name 'dispatcherServlet'
23/11/2018:18:47:54.350 [http-nio-9080-exec-1] E o.a.c.c.C.[.[.[.[dispatcherServlet] --- Servlet.service() for servlet [dispatcherServlet] threw exception
java.lang.IllegalArgumentException: No converter found for return value of type: class java.util.LinkedHashMap




Whereas, when I put management.port=8090 (same as the server port), this error is not thrown when I open a random link.



Is there a way to add a default request handler on the actuator port when it is different from the server port in a spring boot application?










share|improve this question
















In my Java application, I have kept the server port at: 8090
And the property management.port=9080



Now, in my browser, when I open a random link (http://localhost:9080) on the actuator port, my application throws the following error:




No mapping found for HTTP request with URI [/] in DispatcherServlet with name 'dispatcherServlet'
23/11/2018:18:47:54.350 [http-nio-9080-exec-1] E o.a.c.c.C.[.[.[.[dispatcherServlet] --- Servlet.service() for servlet [dispatcherServlet] threw exception
java.lang.IllegalArgumentException: No converter found for return value of type: class java.util.LinkedHashMap




Whereas, when I put management.port=8090 (same as the server port), this error is not thrown when I open a random link.



Is there a way to add a default request handler on the actuator port when it is different from the server port in a spring boot application?







java spring spring-mvc spring-boot spring-boot-actuator






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 23 '18 at 14:21









Catarina Ferreira

5751622




5751622










asked Nov 23 '18 at 13:47









Rishabh SanghiRishabh Sanghi

83




83













  • Can you show your pom.xml?

    – Sukhpal Singh
    Nov 23 '18 at 15:03











  • I'm not sure I can do that, but could you tell me what you're looking for? I have added the jackson dependency.

    – Rishabh Sanghi
    Nov 23 '18 at 17:22











  • Your spring-boot version and jackson dependency which you just confirmed is there.

    – Sukhpal Singh
    Nov 23 '18 at 17:23











  • <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>1.5.10.RELEASE</version> <relativePath/> <!-- lookup parent from repository --> </parent>

    – Rishabh Sanghi
    Nov 23 '18 at 18:39













  • See Add DefaultHandlerExceptionResolver to child context. Try upgrading to 1.5.16.RELEASE

    – Sukhpal Singh
    Nov 24 '18 at 7:29



















  • Can you show your pom.xml?

    – Sukhpal Singh
    Nov 23 '18 at 15:03











  • I'm not sure I can do that, but could you tell me what you're looking for? I have added the jackson dependency.

    – Rishabh Sanghi
    Nov 23 '18 at 17:22











  • Your spring-boot version and jackson dependency which you just confirmed is there.

    – Sukhpal Singh
    Nov 23 '18 at 17:23











  • <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>1.5.10.RELEASE</version> <relativePath/> <!-- lookup parent from repository --> </parent>

    – Rishabh Sanghi
    Nov 23 '18 at 18:39













  • See Add DefaultHandlerExceptionResolver to child context. Try upgrading to 1.5.16.RELEASE

    – Sukhpal Singh
    Nov 24 '18 at 7:29

















Can you show your pom.xml?

– Sukhpal Singh
Nov 23 '18 at 15:03





Can you show your pom.xml?

– Sukhpal Singh
Nov 23 '18 at 15:03













I'm not sure I can do that, but could you tell me what you're looking for? I have added the jackson dependency.

– Rishabh Sanghi
Nov 23 '18 at 17:22





I'm not sure I can do that, but could you tell me what you're looking for? I have added the jackson dependency.

– Rishabh Sanghi
Nov 23 '18 at 17:22













Your spring-boot version and jackson dependency which you just confirmed is there.

– Sukhpal Singh
Nov 23 '18 at 17:23





Your spring-boot version and jackson dependency which you just confirmed is there.

– Sukhpal Singh
Nov 23 '18 at 17:23













<parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>1.5.10.RELEASE</version> <relativePath/> <!-- lookup parent from repository --> </parent>

– Rishabh Sanghi
Nov 23 '18 at 18:39







<parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>1.5.10.RELEASE</version> <relativePath/> <!-- lookup parent from repository --> </parent>

– Rishabh Sanghi
Nov 23 '18 at 18:39















See Add DefaultHandlerExceptionResolver to child context. Try upgrading to 1.5.16.RELEASE

– Sukhpal Singh
Nov 24 '18 at 7:29





See Add DefaultHandlerExceptionResolver to child context. Try upgrading to 1.5.16.RELEASE

– Sukhpal Singh
Nov 24 '18 at 7:29












1 Answer
1






active

oldest

votes


















1














In a standalone application, the Actuator HTTP port defaults to the same as the main HTTP port. To make the application listen on a different port, set the external property: management.server.port. To listen on a completely different network address (such as when you have an internal network for management and an external one for user applications), you can also set management.server.address to a valid IP address to which the server is able to bind.






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',
    autoActivateHeartbeat: false,
    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%2f53447892%2fspring-boot-application-throwing-error-on-actuator-port%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









    1














    In a standalone application, the Actuator HTTP port defaults to the same as the main HTTP port. To make the application listen on a different port, set the external property: management.server.port. To listen on a completely different network address (such as when you have an internal network for management and an external one for user applications), you can also set management.server.address to a valid IP address to which the server is able to bind.






    share|improve this answer




























      1














      In a standalone application, the Actuator HTTP port defaults to the same as the main HTTP port. To make the application listen on a different port, set the external property: management.server.port. To listen on a completely different network address (such as when you have an internal network for management and an external one for user applications), you can also set management.server.address to a valid IP address to which the server is able to bind.






      share|improve this answer


























        1












        1








        1







        In a standalone application, the Actuator HTTP port defaults to the same as the main HTTP port. To make the application listen on a different port, set the external property: management.server.port. To listen on a completely different network address (such as when you have an internal network for management and an external one for user applications), you can also set management.server.address to a valid IP address to which the server is able to bind.






        share|improve this answer













        In a standalone application, the Actuator HTTP port defaults to the same as the main HTTP port. To make the application listen on a different port, set the external property: management.server.port. To listen on a completely different network address (such as when you have an internal network for management and an external one for user applications), you can also set management.server.address to a valid IP address to which the server is able to bind.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Nov 23 '18 at 14:09









        INDRESH KHANDELWALINDRESH KHANDELWAL

        848




        848
































            draft saved

            draft discarded




















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53447892%2fspring-boot-application-throwing-error-on-actuator-port%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