SpringSourceTools | Converting Maven legacy project error - maven

I'm having a trouble converting a legacy Maven project.
I tried :-
Right click project --> Configure --> Covert legacy Maven projects
and it gives me an error
using m2e (1.0.2) plungin for SpringSourceTools IDE
Thanks.

Maybe the project was created with the old Eclipse M2Eclipse plugin. Look at my answer to this question to see whether it helps you.

Related

Kotlin complains about API version not supported

I'm relatively new to Kotlin.
I did create a test project, just the Hello World for now.
Compile/Package OK, then when I try to run the main.kt :
Kotlin: API version 1.1 is no longer supported; please, use version 1.2 or greater.
Is driving me nuts.
Ok, here some info and things I did :
Ubuntu 18.04
IntelliJ Idea Ultimate 2020.3 - all plugins/libraries updated
Kotlin project created from Project --> Kotlin --> Console Application --> SDK 1.8 --> Maven (need to simulate another environment that has similar settings)
On Settings/Build/Kotlin Compiler I selected Language version 1.4
When building I have only some warnings and I did notice this one :
[WARNING] Runtime JAR files in the classpath should have the same version. These files were found in the classpath:
/home/steve/.m2/repository/org/jetbrains/kotlin/kotlin-stdlib/1.1.1/kotlin-stdlib-1.1.1.jar (version 1.1)
/home/steve/.m2/repository/org/jetbrains/kotlin/kotlin-stdlib-jdk8/1.4.31/kotlin-stdlib-jdk8-1.4.31.jar (version 1.4)
/home/steve/.m2/repository/org/jetbrains/kotlin/kotlin-stdlib-jdk7/1.4.31/kotlin-stdlib-jdk7-1.4.31.jar (version 1.4)
So it seems is still importing a stdlib 1.1.1, I did try to remove manually it but without success, is always there.
The POM only has this from jetbrains :
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-stdlib-jdk8</artifactId>
<version>1.4.31</version>
</dependency>
Can anybody please give me some suggestions about how to fix this kind of problem ?
Thanks
STeve
Ok, I did restart from scratch many times trying to identify the problem and I think I did it, i.e. I identified the problem but I don't have a solution.
Starting from scratch everything is working, however I need to add to the project some classes I created in other projects in order to test them.
One of the class imported uses a library called khttp.
Well the moment I add this library as dependence in the project, even without adding any code that use it, screw up everything and I end up with the error :
Kotlin: API version 1.0 is no longer supported; please, use version 1.3 or greater.
The ONLY way I found so far to solve the problem is to remove from the POM the dependency of the library.
So I guess that the problem is IN the library.
If I can't find a solution I guess I need to don't use khttp.
Thanks
Go to
Intellij Preferences -> Build, Execution, Deployment -> Compiler -> Kotlin Compiler. Update Language version
and Api version to the one you wish.
**Click run again it should work fine.
for me it worked like this: right click on project and go to
project settings -> modules -> Kotlin
there I set the API Version to 1.5
I update the Kotlin dependencies version in pom.xml from 1.3.61 to 1.5.10 and it's ok for me
Project Structure>Modules>General
When you go there you gonna see 2 sections right side. Language version and API version. Update these 1.5 and problem will solve easily.

eclipse 4.13.0 - dependency repository

I recently downloaded eclipse ee so I can learn more about Java Spring Framework. I am certain that I installed the correct Spring IDE plugin and a Maven Integration plugin is already pre-installed, I double checked. I ran into the issue when I began a new Maven project and I tried adding Spring Dependencies in the pom.xml file. It seems as if eclipse is not looking in the Global Repository because it cannot find any dependencies from the Spring Framework.
I've tried looking online for a solution. Most posts say to check the preferences on Maven and make sure to select the 'Download repository index updates on starup'. I tried that but still no luck.
If anyone has a solution please let me know
pom.xml screenshot

Why i should add dynamic web module when installing maven facet?

I want to add Maven facet to some project in Eclipse, but when I do that, it adds Dynamic Web Module to the project.
The first question is why ?
Second is how can I make it without adding web module??
thanks :)
I assume you are using MyEclipse, rather than just eclipse, with the m2e plugin. Also, I'm assuming the latest release of MyEclipse (2015 CI). If these assumptions are correct, note that the facet your are adding is for Maven Support of Java EE projects, which is why it is asking for the web project facet version. If you simply want to convert a java project to a maven project, right click on the project then select Configure->Convert to Maven project.

No AspectJ getter/setter -- upgrade Roo from 1.1.5 to 1.2.1

I am upgrading current project from Roo 1.1.5 to 1.2.1.
I have noticed there are some new features in Roo 1.2.1 to facilitate JPA functionality, i.e. #RooEntity to #RooJpaActiveRecord, but I thought when I open Roo shell in STS it could handler that conversion automatically...I can still achieve that manually, however, after I change the annotation name, no matter I use poll now or re-build the project, all the getter/setter/finder/entityManager are error out due to no AspectJ injection, actually I can see the aspectJ files are generated, STS just cannot identify them with the entity java file. So suddenly the whole project falls apart.
Please, geniuses on the stack, let me know how to fix that. Many thanks in advance.
I have figured out the solution:
Simply speaking: make sure running the project as a Maven project.
How: Right click project->Configure->Convert to Maven Project. Then run Right click project -> Maven -> Update Project Configuration.
Maven will build the project once again with aspect injection. I think the problem is previously my project is compiled under Spring Tools -> Update Maven Dependencies where if the STS/AspectJ Tool stop working, then the project will suffer from missing aspect injection(still thinking it is could be a remaining bug of STS, this issue may be very specific but still STS fail the job).
Sorry I have to answer my own question
Make sure you clean your project eclipse style. That is run Project->Clean.

Project import error when using Eclipse

I am getting the following error when trying to import some existing project (couple of years old project).
"No marketplace entries found to handle maven-antrun-plugin:1.3:run in Eclipse. Please see Help for more information."
I have tried to read information on this error.. but can't find anything that tell what's wrong, and how to fix it.
Help? I have Eclipse Indigo, and M2E Eclipse Plugin
Update - Looks like this is related to Eclipse Indigo having Maven 3, and my pom xml files being old (maven2). I am reverting back to Eclipse Ganymede... :(
This probably relates to a M2E connector not existing for the "run" goal of the maven-antrun-plugin. See http://objectledge.org/confluence/display/TOOLS/M2E+Connectors for more information.
Eclipse is only able to perform a subset of Maven build functions, and the M2E Eclipse plugin helps expand Eclipse's repertoire using its "Connectors", which are available for download in the Marketplace.

Resources