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

Add all examples from the tutorial #1

Open
albertolluch opened this issue Jan 5, 2018 · 3 comments
Open

Add all examples from the tutorial #1

albertolluch opened this issue Jan 5, 2018 · 3 comments
Assignees
Labels
help wanted Extra attention is needed

Comments

@albertolluch
Copy link
Member

albertolluch commented Jan 5, 2018

Port to Java all go-based examples from the tutorial.

@albertolluch albertolluch added the help wanted Extra attention is needed label Jan 5, 2018
@albertolluch albertolluch self-assigned this Jan 5, 2018
@dobau
Copy link

dobau commented Jan 16, 2018

@albertolluch What that code should to do?

space.Query("stop")

The first example is here, but I don't know what this part do.
Hmmm, and the example I am using gradle. Is it OK for you?

@albertolluch
Copy link
Member Author

Thanks @dobau I will check your example as soon as possible, as well as the best way to upload Java projects. I need to discuss whether to use gradle or anything else with @michele-loreti .

As for your question, the point is that Java and Go deal differently with termination of the main thread/routine: in Java the main thread waits for all pending (non-demon) threads, while in Go the main routine kills all other routines when it terminates.

So, in the examples in Go I sometimes use space.Query("stop") (or a similar blocking action) to prevent termination of the entire application. Sometimes this makes sense in the example, in some other cases it doesn't but I had no time to implement a protocol for termination detection.

@dobau
Copy link

dobau commented Jan 17, 2018

Thanks for you answer.

I will try change a little logic about "stop" command.
And about use gradle, maven, or only java without automation build ask to loreti.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants