Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't import "com.structurizr.api.StructurizrClient" #26

Closed
thefooly opened this issue Apr 25, 2016 · 2 comments
Closed

Can't import "com.structurizr.api.StructurizrClient" #26

thefooly opened this issue Apr 25, 2016 · 2 comments

Comments

@thefooly
Copy link

Hello,

I am trying to use Structurizr with Maven, but unfortunately I can't import the "com.structurizr.api.StructurizrClient" class (version 0.6.0) even if I am following the tutorial you provided.

I ran the "./gradlew publishToMavenLocal" command and I added the dependencies to my pom file. Everything loads and works fine until I try to import the "com.structurizr.api.StructurizrClient" class. In fact in my dependencies (even if I have them in my pom file), I can't see any jar called "structuriz-client-0.6.0.jar".

I checked in my local Maven repository and I couldn't find the jar there. I can't manually download the jar file from Bintray, so I tried to find another solution to my problem.

Currently I made it work by downloading version 0.3.2 of Structurizr and then by manually adding to the build path of my project "structuriz-client-0.3.2.jar". This allows me to import (and use) the "com.structurizr.api.StructurizrClient" class.

It looks like that in the Bintray repository the client-0.6.0 jar file is not there, or am I doing anything wrong?

Thanks!

@thefooly
Copy link
Author

thefooly commented Apr 25, 2016

Sorry for the double post:

I saw in a commit that you merged structurizr-client into structurizr-core. Unfortunately the "api" package is not inside the core.jar (even if in the git repository it is there). Meaning that I can't import it without doing the workaround I explained above.

Maybe the Bintray jar holds an old version of the core-0.6.0 file without the api package?

@simonbrowndotje
Copy link
Contributor

The structurizr-client-0.6.0.jar file certainly seems to be on Bintray -> https://bintray.com/structurizr/maven/structurizr-java/0.6.0/view#files/com/structurizr/structurizr-client/0.6.0

Since the files are hosted on Bintray (jcenter) rather than Maven Central, you'll need to add "http://jcenter.bintray.com" as an additional repository in your Maven build file -> https://maven.apache.org/guides/mini/guide-multiple-repositories.html

Apologies, this is missing from the instructions. Let me know if that fixes the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants