"type Routes is not a member of package ac"

I tried to create my first atlassian connect application with play framework according to this tutorial https://bitbucket.org/atlassian/atlassian-connect-play-java. So I've installed play activator in version 1.3.5. Then changed a few files like it was written in the tutorial. So now my build.sbt file looks like this:

name := """play-java"""

version := "1.0-SNAPSHOT"

lazy val root = (project in file(".")).enablePlugins(PlayJava)

scalaVersion := "2.10.4"

//libraryDependencies ++= Seq(
//  javaJdbc,
//  cache,
//  javaWs
//)

resolvers += "Atlassian's Maven Public Repository" at "https://maven.atlassian.com/content/groups/public"

resolvers += "Local Maven Repository" at ""+Path.userHome.asFile.toURI.toURL+"/.m2/repository"

libraryDependencies ++= Seq(
    javaJdbc,
    cache,
    javaWs,
    javaCore,
    javaJpa,
    "com.atlassian.connect" % "ac-play-java_2.10" % "0.10.1" withSources()
    // your other dependencies go there
)



// Play provides two styles of routers, one expects its actions to be injected, the
// other, legacy style, accesses its actions statically.
routesGenerator := InjectedRoutesGenerator

And this is my conf/routes file:

# Routes
# This file defines all application routes (Higher priority routes first)
# ~~~~
# Home page
# GET     /                           controllers.Application.index()
->        /                           ac.Routes
# Map static resources from the /public folder to the /assets URL path
# GET     /assets/*file               controllers.Assets.versioned(path="/public", file: Asset)

I've changed ac.key and ac.name in con/application.conf as well and configured database.

Earlier I tried to use some 2.11.x scala version but there were some conflicts in dependencies versions so I've downloaded scala 2.10.4 and these problems disappeared. But when I open my application with browser I see error "type Routes is not a member of package ac" and it points to line -> / ac.Routes in conf/routes. So why this problem appears?

1 answer

Problem resolved. Change version of play framework to 2.2.4 helped for me (Probably I used 2.4.2 before)

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,856 views 12 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot