title: How can I add spring-security-dependency with gradle in IntelliJ?
body: <p>I would like to use the dependency:
  <code>implementation 'org.springframework.boot:spring-boot-starter-security'</code>
  in my IntelliJ-project, but for any reason, it cannot resolve this dependency.</p>
  
  <p>These are my dependencies. The relevant one is <code>spring-boot-starter-security</code>.</p>
  
  <pre><code>dependencies {
  implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
  implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
  implementation 'org.springframework.boot:spring-boot-starter-web'
  implementation 'org.springframework.boot:spring-boot-starter-security'
  developmentOnly 'org.springframework.boot:spring-boot-devtools'
  runtimeOnly 'com.h2database:h2'
  testImplementation('org.springframework.boot:spring-boot-starter-test') {
      exclude group: 'org.junit.vintage', module: 'junit-vintage-engine'
  }
  runtime('org.springframework.boot:spring-boot-devtools')
  }
  </code></pre>
  
  <p>For any reason I get this error message, when starting boot-run:</p>
  
  <p><a href="https://i.stack.imgur.com/Qq6tt.png" rel="nofollow noreferrer">Error-message when starting boot-run</a></p>
  
  <p>Here the whole build.gradle-file:</p>
  
  <pre><code>    plugins {
      id 'org.springframework.boot' version '2.2.7.RELEASE'
      id 'io.spring.dependency-management' version '1.0.9.RELEASE'
      id 'java'
  }
  
  group = 'de.hohenheim'
  version = '0.0.1-SNAPSHOT'
  sourceCompatibility = '11'
  
  configurations {
      developmentOnly
      runtimeClasspath {
          extendsFrom developmentOnly
      }
  }
  
  repositories {
      mavenCentral()
  }
  
  dependencies {
      implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
      implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
      implementation 'org.springframework.boot:spring-boot-starter-web'
      implementation 'org.springframework.boot:spring-boot-starter-security'
      developmentOnly 'org.springframework.boot:spring-boot-devtools'
      runtimeOnly 'com.h2database:h2'
      testImplementation('org.springframework.boot:spring-boot-starter-test') {
          exclude group: 'org.junit.vintage', module: 'junit-vintage-engine'
      }
      runtime('org.springframework.boot:spring-boot-devtools')
  }
  
  test {
      useJUnitPlatform()
  }
  
  bootRun {
      sourceResources(sourceSets.main)
  }
  </code></pre>