in my case, i solved weird issues in spring tools suite (essentially eclipse) after i tried to upgrade spring boot and the changes didn't seem to be taking effect.

right click on your project -> gradle -> refresh gradle project


i tried all above options but was still getting error, in my case issue was i have not setup gradle installation directory in eclipse, following worked:

eclipse -> window -> preferences -> gradle -> "select local installation directory"

click on browse button and provide path.

even though question is answered, thought to share in case somebody else is facing similar issue.

cheers !


you have to make sure that "dependency management" is enabled. to do so, right click on the project name, go to the "gradle" sub-menu and click on "enable dependency management". once you do that, gradle should load all the dependencies for you.


looking at the eclipse plugin docs i found some useful tasks that rebuilt my classpath and updated the required dependencies.

  • first try gradle cleaneclipse to clean the eclipse configuration completely. if this doesn;t work you may try more specific tasks:
    • gradle cleaneclipseproject to remove the .project file
    • gradle cleaneclipseclasspath to empty the project's classpath
  • finally gradle eclipse to rebuild the eclipse configuration


follow those steps to update gradle project in eclipse:

  1. first, please check you have include eclipse gradle plugin. apply plugin : 'eclipse'
  2. then go to your project directory in terminal. type gradle clean and then gradle eclipse.
  3. then go to project in eclipse and refresh the project (go to project explorer, select root of the project and hit f5 to refresh, or right click and select refresh in context menu).

enter image description here


you have to select "refresh dependencies" in the "gradle" context menu that appears when you right-click the project in the package explorer.

Related Query

More Query from same tag