[
https://issues.apache.org/jira/browse/IGNITE-9396?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16596190#comment-16596190
]
Oleg Ignatenko edited comment on IGNITE-9396 at 8/30/18 7:47 PM:
-----------------------------------------------------------------
I think I managed to reproduce the problem on my machine using IntelliJ Idea
(Ultimate 2018.1).
For that, I first checked what is the documented way to build examples per
[README.txt|https://github.com/apache/ignite/blob/master/examples/README.txt]:
"to start running you simply need to import provided `pom.xml` file into your
favourite IDE." In order to reproduce clean start I removed everything that was
cashed in my local maven repo and invalidated Idea caches. After that I tried
to build and launch an example and got compile errors similar to reported here
(specific example tested was {{KMeansClusterizationExample}} but it probably
doesn't really matter).
To find out how this can be corrected I decided to re-check how we build
[examples at
Teamcity|https://ci.ignite.apache.org/viewType.html?buildTypeId=IgniteTests24Java8_Examples]
because this way has proven to be clean and reliably working. Checking build
settings at Teamcity it turned out that prior to building examples they run a
maven (install) build for the Ignite. I tried the same on my machine and after
I did the install build of Ignite as described in
[DEVNOTES.txt|https://github.com/apache/ignite/blob/master/DEVNOTES.txt]
examples successfully loaded and built in my IDE and started working as
expected.
So far it looks like root issue is that README instructions in examples are
somewhat incomplete, possibly these can be expanded as follows (text for adding
is in _italic_ font):
{quote}...to start running you simply need to import provided `pom.xml` file
into your favourite IDE.
_Note working with examples assumes that you have Ignite already installed. If
you use source bundle this means it has built as described in DEVNOTES.txt in
Ignite project root._
{quote}
[~dmagda] kindly agreed to discuss these matters on Thursday.
-----
Follow-up: per discussion with Denis change suggested above is the wrong way to
address this issue. This is because readme file is intended for end users who
are expected to use release version and because of that would obtain necessary
dependencies straight from maven central. For these users proposed addition
would be superfluous and quite confusing.
Issue described in this ticket concerns only developers who use snapshot
dependencies and because of that can't rely on maven central repository. The
right way to instruct this category of users is to document it in a separate
file (similar to [DEVNOTES.txt in Ignite
root|https://github.com/apache/ignite/blob/master/DEVNOTES.txt]).
was (Author: oignatenko):
I think I managed to reproduce the problem on my machine using IntelliJ Idea
(Ultimate 2018.1).
For that, I first checked what is the documented way to build examples per
[README.txt|https://github.com/apache/ignite/blob/master/examples/README.txt]:
"to start running you simply need to import provided `pom.xml` file into your
favourite IDE." In order to reproduce clean start I removed everything that was
cashed in my local maven repo and invalidated Idea caches. After that I tried
to build and launch an example and got compile errors similar to reported here
(specific example tested was {{KMeansClusterizationExample}} but it probably
doesn't really matter).
To find out how this can be corrected I decided to re-check how we build
[examples at
Teamcity|https://ci.ignite.apache.org/viewType.html?buildTypeId=IgniteTests24Java8_Examples]
because this way has proven to be clean and reliably working. Checking build
settings at Teamcity it turned out that prior to building examples they run a
maven (install) build for the Ignite. I tried the same on my machine and after
I did the install build of Ignite as described in
[DEVNOTES.txt|https://github.com/apache/ignite/blob/master/DEVNOTES.txt]
examples successfully loaded and built in my IDE and started working as
expected.
So far it looks like root issue is that README instructions in examples are
somewhat incomplete, possibly these can be expanded as follows (text for adding
is in _italic_ font):
{quote}...to start running you simply need to import provided `pom.xml` file
into your favourite IDE.
_Note working with examples assumes that you have Ignite already installed. If
you use source bundle this means it has built as described in DEVNOTES.txt in
Ignite project root._{quote}
[~dmagda] kindly agreed to discuss these matters on Thursday.
> ML Examples: can't run examples, not enough dependencies in pom.xml
> -------------------------------------------------------------------
>
> Key: IGNITE-9396
> URL: https://issues.apache.org/jira/browse/IGNITE-9396
> Project: Ignite
> Issue Type: Bug
> Components: ml
> Affects Versions: 2.7
> Reporter: Stepan Pilschikov
> Assignee: Oleg Ignatenko
> Priority: Major
> Fix For: 2.7
>
>
> Trying to run ml-examples and can't compile example project because several
> dependencies didn't added in pom.xml
> Execution:
> Using JB IDEA Run->Run class to execute current class
> or
> `java -classpath [all classpaths which are listed in pom file] class name`
> or compile with maven also failed
> `mvn clean compile`
> Exception:
> Can't compile project. not enough dependencies
> Missing dependencies:
> {code:xml}
> <dependency>
> <groupId>com.github.fommil.netlib</groupId>
> <artifactId>core</artifactId>
> </dependency>
> <dependency>
> <groupId>org.springframework.data</groupId>
> <artifactId>spring-data-commons</artifactId>
> </dependency>
> <dependency>
> <groupId>org.springframework</groupId>
> <artifactId>spring-beans</artifactId>
> </dependency>
> <dependency>
> <groupId>org.springframework</groupId>
> <artifactId>spring-context</artifactId>
> </dependency>
> <dependency>
> <groupId>com.h2database</groupId>
> <artifactId>h2</artifactId>
> </dependency>
> {code}
> com.github.fommil.netlib, springframework.* and h2 need to run -
> org.apache.ignite.examples.ml.dataset.AlgorithmSpecificDatasetExample
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)