Spring framework boot does not exist?











up vote
0
down vote

favorite












I am running the following application:



package com.h2o;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class H2oRestServiceApplication {

public static void main(String args) {
SpringApplication.run(H2oRestServiceApplication.class, args);
}
}


My pom.xml file can be found here: https://github.com/shilpakancharla/ReutersSearchEngine/blob/master/h2o/pom.xml



I am getting the following errors when trying to run javac



H2oRestServiceApplication.java from my terminal: 

H2oRestServiceApplication.java:3: error: package org.springframework.boot does not exist
import org.springframework.boot.SpringApplication;
^
H2oRestServiceApplication.java:4: error: package org.springframework.boot.autoconfigure does not exist
import org.springframework.boot.autoconfigure.SpringBootApplication;
^
H2oRestServiceApplication.java:6: error: cannot find symbol
@SpringBootApplication
^
symbol: class SpringBootApplication
H2oRestServiceApplication.java:10: error: cannot find symbol
SpringApplication.run(H2oRestServiceApplication.class, args);
^
symbol: variable SpringApplication
location: class H2oRestServiceApplication
4 errors


Could someone explain if there is something wrong with my pom.xml? I am not sure how to fix this or what dependencies I am missing.










share|improve this question






















  • You are running javac in the same folder where your application lays ?
    – Mykhailo Moskura
    Nov 19 at 0:22










  • Did you run a build so that the dependencies in your pom actually get downloaded? Running it from an IDE will be easier than using javac in terminal.
    – Kartik
    Nov 19 at 0:24










  • Yes, I am in the same folder that I'm running it in.
    – user10335564
    Nov 19 at 0:25










  • @Kartik I don not think I have done that. How do I do that?
    – user10335564
    Nov 19 at 0:26










  • please follow this and this guide
    – Kartik
    Nov 19 at 0:29















up vote
0
down vote

favorite












I am running the following application:



package com.h2o;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class H2oRestServiceApplication {

public static void main(String args) {
SpringApplication.run(H2oRestServiceApplication.class, args);
}
}


My pom.xml file can be found here: https://github.com/shilpakancharla/ReutersSearchEngine/blob/master/h2o/pom.xml



I am getting the following errors when trying to run javac



H2oRestServiceApplication.java from my terminal: 

H2oRestServiceApplication.java:3: error: package org.springframework.boot does not exist
import org.springframework.boot.SpringApplication;
^
H2oRestServiceApplication.java:4: error: package org.springframework.boot.autoconfigure does not exist
import org.springframework.boot.autoconfigure.SpringBootApplication;
^
H2oRestServiceApplication.java:6: error: cannot find symbol
@SpringBootApplication
^
symbol: class SpringBootApplication
H2oRestServiceApplication.java:10: error: cannot find symbol
SpringApplication.run(H2oRestServiceApplication.class, args);
^
symbol: variable SpringApplication
location: class H2oRestServiceApplication
4 errors


Could someone explain if there is something wrong with my pom.xml? I am not sure how to fix this or what dependencies I am missing.










share|improve this question






















  • You are running javac in the same folder where your application lays ?
    – Mykhailo Moskura
    Nov 19 at 0:22










  • Did you run a build so that the dependencies in your pom actually get downloaded? Running it from an IDE will be easier than using javac in terminal.
    – Kartik
    Nov 19 at 0:24










  • Yes, I am in the same folder that I'm running it in.
    – user10335564
    Nov 19 at 0:25










  • @Kartik I don not think I have done that. How do I do that?
    – user10335564
    Nov 19 at 0:26










  • please follow this and this guide
    – Kartik
    Nov 19 at 0:29













up vote
0
down vote

favorite









up vote
0
down vote

favorite











I am running the following application:



package com.h2o;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class H2oRestServiceApplication {

public static void main(String args) {
SpringApplication.run(H2oRestServiceApplication.class, args);
}
}


My pom.xml file can be found here: https://github.com/shilpakancharla/ReutersSearchEngine/blob/master/h2o/pom.xml



I am getting the following errors when trying to run javac



H2oRestServiceApplication.java from my terminal: 

H2oRestServiceApplication.java:3: error: package org.springframework.boot does not exist
import org.springframework.boot.SpringApplication;
^
H2oRestServiceApplication.java:4: error: package org.springframework.boot.autoconfigure does not exist
import org.springframework.boot.autoconfigure.SpringBootApplication;
^
H2oRestServiceApplication.java:6: error: cannot find symbol
@SpringBootApplication
^
symbol: class SpringBootApplication
H2oRestServiceApplication.java:10: error: cannot find symbol
SpringApplication.run(H2oRestServiceApplication.class, args);
^
symbol: variable SpringApplication
location: class H2oRestServiceApplication
4 errors


Could someone explain if there is something wrong with my pom.xml? I am not sure how to fix this or what dependencies I am missing.










share|improve this question













I am running the following application:



package com.h2o;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class H2oRestServiceApplication {

public static void main(String args) {
SpringApplication.run(H2oRestServiceApplication.class, args);
}
}


My pom.xml file can be found here: https://github.com/shilpakancharla/ReutersSearchEngine/blob/master/h2o/pom.xml



I am getting the following errors when trying to run javac



H2oRestServiceApplication.java from my terminal: 

H2oRestServiceApplication.java:3: error: package org.springframework.boot does not exist
import org.springframework.boot.SpringApplication;
^
H2oRestServiceApplication.java:4: error: package org.springframework.boot.autoconfigure does not exist
import org.springframework.boot.autoconfigure.SpringBootApplication;
^
H2oRestServiceApplication.java:6: error: cannot find symbol
@SpringBootApplication
^
symbol: class SpringBootApplication
H2oRestServiceApplication.java:10: error: cannot find symbol
SpringApplication.run(H2oRestServiceApplication.class, args);
^
symbol: variable SpringApplication
location: class H2oRestServiceApplication
4 errors


Could someone explain if there is something wrong with my pom.xml? I am not sure how to fix this or what dependencies I am missing.







java rest api spring-boot






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 19 at 0:13









user10335564

32




32












  • You are running javac in the same folder where your application lays ?
    – Mykhailo Moskura
    Nov 19 at 0:22










  • Did you run a build so that the dependencies in your pom actually get downloaded? Running it from an IDE will be easier than using javac in terminal.
    – Kartik
    Nov 19 at 0:24










  • Yes, I am in the same folder that I'm running it in.
    – user10335564
    Nov 19 at 0:25










  • @Kartik I don not think I have done that. How do I do that?
    – user10335564
    Nov 19 at 0:26










  • please follow this and this guide
    – Kartik
    Nov 19 at 0:29


















  • You are running javac in the same folder where your application lays ?
    – Mykhailo Moskura
    Nov 19 at 0:22










  • Did you run a build so that the dependencies in your pom actually get downloaded? Running it from an IDE will be easier than using javac in terminal.
    – Kartik
    Nov 19 at 0:24










  • Yes, I am in the same folder that I'm running it in.
    – user10335564
    Nov 19 at 0:25










  • @Kartik I don not think I have done that. How do I do that?
    – user10335564
    Nov 19 at 0:26










  • please follow this and this guide
    – Kartik
    Nov 19 at 0:29
















You are running javac in the same folder where your application lays ?
– Mykhailo Moskura
Nov 19 at 0:22




You are running javac in the same folder where your application lays ?
– Mykhailo Moskura
Nov 19 at 0:22












Did you run a build so that the dependencies in your pom actually get downloaded? Running it from an IDE will be easier than using javac in terminal.
– Kartik
Nov 19 at 0:24




Did you run a build so that the dependencies in your pom actually get downloaded? Running it from an IDE will be easier than using javac in terminal.
– Kartik
Nov 19 at 0:24












Yes, I am in the same folder that I'm running it in.
– user10335564
Nov 19 at 0:25




Yes, I am in the same folder that I'm running it in.
– user10335564
Nov 19 at 0:25












@Kartik I don not think I have done that. How do I do that?
– user10335564
Nov 19 at 0:26




@Kartik I don not think I have done that. How do I do that?
– user10335564
Nov 19 at 0:26












please follow this and this guide
– Kartik
Nov 19 at 0:29




please follow this and this guide
– Kartik
Nov 19 at 0:29












1 Answer
1






active

oldest

votes

















up vote
1
down vote













I have done the below steps and your application is up and running -- I was able to view the swagger UI as well.



1) Cloned your repository



git clone https://github.com/shilpakancharla/ReutersSearchEngine.git


2) Switched to your project directory



cd ReutersSearchEngine/h2o


3) Did a Maven Clean Package (as your's is a maven based spring boot project)



mvn clean package


Waited for maven to download dependencies, compile sources and build an executable jar.



It created a jar with name h2o-0.0.1-SNAPSHOT.jar inside target directory.



4) Simply launched the jar file using the below command.



java -jar target/h2o-0.0.1-SNAPSHOT.jar


The application started fine with these logs at the end.



2018-11-19 16:56:01.928  INFO 7288 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 80 (http) with context path ''
2018-11-19 16:56:01.932 INFO 7288 --- [ main] com.h2o.H2oRestServiceApplication : Started H2oRestServiceApplication in 8.595 seconds (JVM running for 9.116)


5) As the application started on port 80, I visited the below address on my browser.



http://localhost/swagger-ui.html


And your swagger-ui showed up as below.



enter image description here



Hope this helps!



If you still face issues, please post it here.






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%2f53366777%2fspring-framework-boot-does-not-exist%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
    1
    down vote













    I have done the below steps and your application is up and running -- I was able to view the swagger UI as well.



    1) Cloned your repository



    git clone https://github.com/shilpakancharla/ReutersSearchEngine.git


    2) Switched to your project directory



    cd ReutersSearchEngine/h2o


    3) Did a Maven Clean Package (as your's is a maven based spring boot project)



    mvn clean package


    Waited for maven to download dependencies, compile sources and build an executable jar.



    It created a jar with name h2o-0.0.1-SNAPSHOT.jar inside target directory.



    4) Simply launched the jar file using the below command.



    java -jar target/h2o-0.0.1-SNAPSHOT.jar


    The application started fine with these logs at the end.



    2018-11-19 16:56:01.928  INFO 7288 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 80 (http) with context path ''
    2018-11-19 16:56:01.932 INFO 7288 --- [ main] com.h2o.H2oRestServiceApplication : Started H2oRestServiceApplication in 8.595 seconds (JVM running for 9.116)


    5) As the application started on port 80, I visited the below address on my browser.



    http://localhost/swagger-ui.html


    And your swagger-ui showed up as below.



    enter image description here



    Hope this helps!



    If you still face issues, please post it here.






    share|improve this answer

























      up vote
      1
      down vote













      I have done the below steps and your application is up and running -- I was able to view the swagger UI as well.



      1) Cloned your repository



      git clone https://github.com/shilpakancharla/ReutersSearchEngine.git


      2) Switched to your project directory



      cd ReutersSearchEngine/h2o


      3) Did a Maven Clean Package (as your's is a maven based spring boot project)



      mvn clean package


      Waited for maven to download dependencies, compile sources and build an executable jar.



      It created a jar with name h2o-0.0.1-SNAPSHOT.jar inside target directory.



      4) Simply launched the jar file using the below command.



      java -jar target/h2o-0.0.1-SNAPSHOT.jar


      The application started fine with these logs at the end.



      2018-11-19 16:56:01.928  INFO 7288 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 80 (http) with context path ''
      2018-11-19 16:56:01.932 INFO 7288 --- [ main] com.h2o.H2oRestServiceApplication : Started H2oRestServiceApplication in 8.595 seconds (JVM running for 9.116)


      5) As the application started on port 80, I visited the below address on my browser.



      http://localhost/swagger-ui.html


      And your swagger-ui showed up as below.



      enter image description here



      Hope this helps!



      If you still face issues, please post it here.






      share|improve this answer























        up vote
        1
        down vote










        up vote
        1
        down vote









        I have done the below steps and your application is up and running -- I was able to view the swagger UI as well.



        1) Cloned your repository



        git clone https://github.com/shilpakancharla/ReutersSearchEngine.git


        2) Switched to your project directory



        cd ReutersSearchEngine/h2o


        3) Did a Maven Clean Package (as your's is a maven based spring boot project)



        mvn clean package


        Waited for maven to download dependencies, compile sources and build an executable jar.



        It created a jar with name h2o-0.0.1-SNAPSHOT.jar inside target directory.



        4) Simply launched the jar file using the below command.



        java -jar target/h2o-0.0.1-SNAPSHOT.jar


        The application started fine with these logs at the end.



        2018-11-19 16:56:01.928  INFO 7288 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 80 (http) with context path ''
        2018-11-19 16:56:01.932 INFO 7288 --- [ main] com.h2o.H2oRestServiceApplication : Started H2oRestServiceApplication in 8.595 seconds (JVM running for 9.116)


        5) As the application started on port 80, I visited the below address on my browser.



        http://localhost/swagger-ui.html


        And your swagger-ui showed up as below.



        enter image description here



        Hope this helps!



        If you still face issues, please post it here.






        share|improve this answer












        I have done the below steps and your application is up and running -- I was able to view the swagger UI as well.



        1) Cloned your repository



        git clone https://github.com/shilpakancharla/ReutersSearchEngine.git


        2) Switched to your project directory



        cd ReutersSearchEngine/h2o


        3) Did a Maven Clean Package (as your's is a maven based spring boot project)



        mvn clean package


        Waited for maven to download dependencies, compile sources and build an executable jar.



        It created a jar with name h2o-0.0.1-SNAPSHOT.jar inside target directory.



        4) Simply launched the jar file using the below command.



        java -jar target/h2o-0.0.1-SNAPSHOT.jar


        The application started fine with these logs at the end.



        2018-11-19 16:56:01.928  INFO 7288 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 80 (http) with context path ''
        2018-11-19 16:56:01.932 INFO 7288 --- [ main] com.h2o.H2oRestServiceApplication : Started H2oRestServiceApplication in 8.595 seconds (JVM running for 9.116)


        5) As the application started on port 80, I visited the below address on my browser.



        http://localhost/swagger-ui.html


        And your swagger-ui showed up as below.



        enter image description here



        Hope this helps!



        If you still face issues, please post it here.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Nov 19 at 11:29









        snmaddula

        2018




        2018






























             

            draft saved


            draft discarded



















































             


            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53366777%2fspring-framework-boot-does-not-exist%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







            Popular posts from this blog

            Ottavio Pratesi

            Tricia Helfer

            15 giugno