title: Bazel Maven migration Transitive Dependencies Scope
body: <p>I am trying to use the <code>generate_workspace</code> on one of the project which has deps and transitive dependencies. Once the<code>generate_workspace.bzl</code> has been generated and I copied it to the WORKSPACE and followed the instruction in the bazel docs. Though I see the deps and their transitive deps listed in the <code>generate_workspace.bzl</code> my project during java_library phase is not able resolve transitive deps.. when I import the same project in IDEA I don't see the jars correctly loaded. </p>
  
  <p>My doubt is for the deps I see the  generate_workspace.bzl is adding its transitve deps as <code>runtime_deps</code> which means they are available only during runt<code>enter code here</code>ime </p>
  
  <p>I have created gist of all the files here 
  <a href="https://gist.github.com/kameshsampath/8a4bdc8b22d85bbe3f243fa1b816e464" rel="nofollow noreferrer">https://gist.github.com/kameshsampath/8a4bdc8b22d85bbe3f243fa1b816e464</a> </p>
  
  <p>Ideally in my maven project I just need <a href="https://gist.github.com/kameshsampath/8a4bdc8b22d85bbe3f243fa1b816e464#file-src_main_build-L8-L9" rel="nofollow noreferrer">https://gist.github.com/kameshsampath/8a4bdc8b22d85bbe3f243fa1b816e464#file-src_main_build-L8-L9</a>, though generate_workspace.bzl has resolved rightly i thought its enough if my src/main/BUILD looks like </p>
  
  <pre><code>java_binary(
        name = "main",
        srcs = glob(["java/**/*.java"]),
        resources = glob(["resources/**"]),
        main_class = "com.redhat.developers.DemoApplication",
        # FIXME why I should import all the jars when they are transitive to spring boot starter
        deps = [
            "//third_party:org_springframework_boot_spring_boot_starter_actuator",
            "//third_party:org_springframework_boot_spring_boot_starter_web",
              ],
  )
  </code></pre>
  
  <p>But sadly that gives lots of compilation errors as transitive deps are not getting loaded as part the above declaration. eventually I have to define like how I did in the <code>https://gist.github.com/kameshsampath/8a4bdc8b22d85bbe3f243fa1b816e464#file-src_main_build</code></p>
  
  <p>src_main_build is BUILD file under package src/main/BUILD
  third_party_BUILD is the BUILD under package third_party/BUILD</p>