Coder Social home page Coder Social logo

cat-boot-structurizr-sample's People

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

devtreff

cat-boot-structurizr-sample's Issues

Unsuccessful in getting up and running with your sample

I really liked the idea of doing the dsl work in Kotlin and taking advantage of some of the nice features of Spring Boot, but I ran into two problems that I was ultimately unable to figure out. :/

The first was how to add a configuration parameters file such that I could read in certain values from it.
Went down a rat-hole of how to get it properly defined and annotated, and for a while I did have it successfully working, but then suddenly it started complaining that the configuration class may not be final. I don't know if it finally picked up a change from Kotlin 1.2.50 to 1.2.60 or something else.

The other problem was that I really needed to take advantage of the structurizr component finders (namely the spring-component-finder to start with). When I was able to run the app using that finder, it spewed out tons of errors saying "A component type must be provided.". Right as I tried to get set up to debug that, the build stopped working and I had to give up.

If there is any chance you guys might add to this demo showing how to use a config property file and how to use a component scanner, it would be really great.

com.structurizr.io.WorkspaceReaderException: Could not read JSON

Greetings!
I am trying to run your example with this dependencies versions:

dependencies {
    compile 'cc.catalysts.boot:cat-boot-structurizr:0.2.24'
    compile "org.springframework.boot:spring-boot-starter:2.0.1.RELEASE"
}

The following error occurs:

➜  cat-boot-structurizr-sample git:(master) ✗ gradle run
:compileJava UP-TO-DATE
:processResources UP-TO-DATE
:classes UP-TO-DATE
:run

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::        (v2.0.1.RELEASE)

2018-04-27 13:52:31.831  INFO 30369 --- [           main] c.c.boot.structurizr.Architecture        : Starting Architecture on lubuntu with PID 30369 (/media/sf_shared/scripts/3.5/cat-boot-structurizr-sample/build/classes/main started by max in /media/sf_shared/scripts/3.5/cat-boot-structurizr-sample)
2018-04-27 13:52:31.838  INFO 30369 --- [           main] c.c.boot.structurizr.Architecture        : No active profile set, falling back to default profiles: default
2018-04-27 13:52:31.978  INFO 30369 --- [           main] s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@69a10787: startup date [Fri Apr 27 13:52:31 MSK 2018]; root of context hierarchy
2018-04-27 13:52:33.895  INFO 30369 --- [           main] o.s.j.e.a.AnnotationMBeanExporter        : Registering beans for JMX exposure on startup
2018-04-27 13:52:33.911  INFO 30369 --- [           main] c.c.b.s.service.StructurizrService       : Added 3 implicit relationships.
2018-04-27 13:52:33.932  INFO 30369 --- [           main] com.structurizr.api.StructurizrClient    : Getting workspace with ID 3
2018-04-27 13:52:34.775 ERROR 30369 --- [           main] com.structurizr.api.StructurizrClient    : com.structurizr.io.WorkspaceReaderException: Could not read JSON
2018-04-27 13:52:34.776 ERROR 30369 --- [           main] com.structurizr.api.StructurizrClient    : com.structurizr.api.StructurizrClientException: com.structurizr.io.WorkspaceReaderException: Could not read JSON
2018-04-27 13:52:34.783 ERROR 30369 --- [           main] c.c.b.s.service.StructurizrService       : Could not put workspace.

com.structurizr.api.StructurizrClientException: com.structurizr.api.StructurizrClientException: com.structurizr.io.WorkspaceReaderException: Could not read JSON
	at com.structurizr.api.StructurizrClient.putWorkspace(StructurizrClient.java:300) ~[structurizr-client-1.0.0-RC5.jar:1.0.0-RC5]
	at cc.catalysts.boot.structurizr.service.StructurizrService.onApplicationEvent(StructurizrService.java:71) [cat-boot-structurizr-0.2.24.jar:na]
	at cc.catalysts.boot.structurizr.service.StructurizrService.onApplicationEvent(StructurizrService.java:28) [cat-boot-structurizr-0.2.24.jar:na]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:172) [spring-context-5.0.5.RELEASE.jar:5.0.5.RELEASE]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:165) [spring-context-5.0.5.RELEASE.jar:5.0.5.RELEASE]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:139) [spring-context-5.0.5.RELEASE.jar:5.0.5.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:400) [spring-context-5.0.5.RELEASE.jar:5.0.5.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:354) [spring-context-5.0.5.RELEASE.jar:5.0.5.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:888) [spring-context-5.0.5.RELEASE.jar:5.0.5.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:553) [spring-context-5.0.5.RELEASE.jar:5.0.5.RELEASE]
	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:759) [spring-boot-2.0.1.RELEASE.jar:2.0.1.RELEASE]
	atringframework.boot.SpringApplication.refreshContext(SpringApplication.java:395) [spring-boot-2.0.1.RELEASE.jar:2.0.1.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:327) [spring-boot-2.0.1.RELEASE.jar:2.0.1.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1255) [spring-boot-2.0.1.RELEASE.jar:2.0.1.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1243) [spring-boot-2.0.1.RELEASE.jar:2.0.1.RELEASE]
	at cc.catalysts.boot.structurizr.Architecture.main(Architecture.java:25) [main/:na]
Caused by: com.structurizr.api.StructurizrClientException: com.structurizr.io.WorkspaceReaderException: Could not read JSON
	at com.structurizr.api.StructurizrClient.getWorkspace(StructurizrClient.java:237) ~[structurizr-client-1.0.0-RC5.jar:1.0.0-RC5]
	at com.structurizr.api.StructurizrClient.putWorkspace(StructurizrClient.java:257) ~[structurizr-client-1.0.0-RC5.jar:1.0.0-RC5]
	... 15 common frames omitted
Caused by: com.structurizr.io.WorkspaceReaderException: Could not read JSON
	at com.structurizr.io.json.JsonReader.read(JsonReader.java:35) ~[structurizr-client-1.0.0-RC5.jar:1.0.0-RC5]
	at com.structurizr.api.StructurizrClient.getWorkspace(StructurizrClient.java:224) ~[structurizr-client-1.0.0-RC5.jar:1.0.0-RC5]
	... 16 common frames omitted
Caused by: com.fasterxml.jackson.core.JsonParseException: Unexpected character ('<' (code 60)): expected a valid value (number, String, array, object, 'true', 'false' or 'null')
 at [Source: java.io.StringReader@29e6eb25; line: 1, column: 2]
	at com.fasterxml.jackson.core.JsonParser._constructError(JsonParser.java:1419) ~[jackson-core-2.4.0.jar:2.4.0]
	at com.fasterxml.jackson.core.base.ParserMinimalBase._reportError(ParserMinimalBase.java:508) ~[jackson-core-2.4.0.jar:2.4.0]
	at com.fasterxml.jackson.core.base.ParserMinimalBase._reportUnexpectedChar(ParserMinimalBase.java:437) ~[jackson-core-2.4.0.jar:2.4.0]
	at com.fasterxml.jackson.core.json.ReaderBasedJsonParser._handleOddValue(ReadesonParser.java:1462) ~[jackson-core-2.4.0.jar:2.4.0]
	at com.fasterxml.jackson.core.json.ReaderBasedJsonParser.nextToken(ReaderBasedJsonParser.java:683) ~[jackson-core-2.4.0.jar:2.4.0]
	at com.fasterxml.jackson.databind.ObjectMapper._initForReading(ObjectMapper.java:3090) ~[jackson-databind-2.4.0.jar:2.4.0]
	at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:3036) ~[jackson-databind-2.4.0.jar:2.4.0]
	at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:2169) ~[jackson-databind-2.4.0.jar:2.4.0]
	at com.structurizr.io.json.JsonReader.read(JsonReader.java:30) ~[structurizr-client-1.0.0-RC5.jar:1.0.0-RC5]
	... 17 common frames omitted

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.