You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@shiro.apache.org by "richard@localmed.com" <ri...@localmed.com> on 2013/06/12 00:19:02 UTC

How to fix Shiro errors in Eclipse?

Hi.

Despite over a week of trying, I have not been able to get the latest Shiro
release (1.2.2) to build successfully in Eclipse (Juno, latest version, all
up to date).  All my other Maven-based projects are fine in Eclipse.  With
shiro-root cleanly imported into Eclipse as a Maven project, I get 2698
errors, mostly of the form "[class] cannot be resolved to a type".  I have
tried every variation of the Eclipse Maven settings I can find, with no
luck.  Building from a command line with "mvn clean install" runs fine.  Has
anyone else run into this problem?  Is there some trick to resolving it?




--
View this message in context: http://shiro-user.582556.n2.nabble.com/How-to-fix-Shiro-errors-in-Eclipse-tp7578835.html
Sent from the Shiro User mailing list archive at Nabble.com.

RE: How to fix Shiro errors in Eclipse?

Posted by Poitras Christian <Ch...@ircm.qc.ca>.
Hi,

It works on my computer. I use Juno SR2 and m2e 1.3.1.
I don't use any special configuration in m2e.

Christian

De : Les Hazlewood [mailto:lhazlewood@apache.org]
Envoyé : June-12-13 12:56 AM
À : user@shiro.apache.org
Objet : Re: How to fix Shiro errors in Eclipse?

I would help if I could, but I'm an IntelliJ user.  Sorry!

--
Les Hazlewood | @lhazlewood
CTO, Stormpath | http://stormpath.com<http://stormpath.com/> | @goStormpath | 888.391.5282

On Tue, Jun 11, 2013 at 3:19 PM, richard@localmed.com<ma...@localmed.com> <ri...@localmed.com>> wrote:
Hi.

Despite over a week of trying, I have not been able to get the latest Shiro
release (1.2.2) to build successfully in Eclipse (Juno, latest version, all
up to date).  All my other Maven-based projects are fine in Eclipse.  With
shiro-root cleanly imported into Eclipse as a Maven project, I get 2698
errors, mostly of the form "[class] cannot be resolved to a type".  I have
tried every variation of the Eclipse Maven settings I can find, with no
luck.  Building from a command line with "mvn clean install" runs fine.  Has
anyone else run into this problem?  Is there some trick to resolving it?




--
View this message in context: http://shiro-user.582556.n2.nabble.com/How-to-fix-Shiro-errors-in-Eclipse-tp7578835.html
Sent from the Shiro User mailing list archive at Nabble.com.


Re: How to fix Shiro errors in Eclipse?

Posted by Les Hazlewood <lh...@apache.org>.
I would help if I could, but I'm an IntelliJ user.  Sorry!

--
Les Hazlewood | @lhazlewood
CTO, Stormpath | http://stormpath.com | @goStormpath | 888.391.5282


On Tue, Jun 11, 2013 at 3:19 PM, richard@localmed.com
<ri...@localmed.com>wrote:

> Hi.
>
> Despite over a week of trying, I have not been able to get the latest Shiro
> release (1.2.2) to build successfully in Eclipse (Juno, latest version, all
> up to date).  All my other Maven-based projects are fine in Eclipse.  With
> shiro-root cleanly imported into Eclipse as a Maven project, I get 2698
> errors, mostly of the form "[class] cannot be resolved to a type".  I have
> tried every variation of the Eclipse Maven settings I can find, with no
> luck.  Building from a command line with "mvn clean install" runs fine.
>  Has
> anyone else run into this problem?  Is there some trick to resolving it?
>
>
>
>
> --
> View this message in context:
> http://shiro-user.582556.n2.nabble.com/How-to-fix-Shiro-errors-in-Eclipse-tp7578835.html
> Sent from the Shiro User mailing list archive at Nabble.com.
>

Re: How to fix Shiro errors in Eclipse?

Posted by Glen Mazza <gl...@gmail.com>.
Just for the email archives, I just did an mvn clean install, then an 
mvn eclipse:eclipse, and then imported the project via Step #2 here: 
http://www.jroller.com/gmazza/entry/web_service_tutorial#EclipseSetup. 
Worked fine for me.

Glen

On 06/12/2013 07:28 PM, richard@localmed.com wrote:
> In case anyone else runs into this problem, here is how I resolved it.
> Essentially, Eclipse has trouble importing multi-module Maven projects.
>
> First, I discovered that there was a hidden alert dialog underneath the
> restart Eclipse popup when I imported the project.  It read:
> An internal error occurred during: "Updating Maven Project".  Unsupported
> IClasspathEntry kind=4
>
> There are various suggestions of how to fix this in online posts, such as:
> http://thetechnodyne.blogspot.com/2012/09/fixing-error-importing-maven.html
> Unfortunately, once you get this error, various .classpath files start to
> become corrupted, and Eclipse becomes more and more confused, and so none of
> these fixes worked for me
>
> I deleted the projects from Eclipse.  I then manually searched and removed
> all Eclipse-related resources in all subdirectories, including .classpath
> and .project files and .settings subdirectories.  Then I reimported
> everything fresh into Eclipse.  I needed to right-click all
> projects->Maven->Update Project... and then Clean and rebuild multiple
> times.  Eventually, the only errors remaining are a few actual Java
> problems:
>
> These I am not going to worry about.
>
>
>
>
>
> --
> View this message in context: http://shiro-user.582556.n2.nabble.com/How-to-fix-Shiro-errors-in-Eclipse-tp7578835p7578842.html
> Sent from the Shiro User mailing list archive at Nabble.com.


Re: How to fix Shiro errors in Eclipse?

Posted by "richard@localmed.com" <ri...@localmed.com>.
In case anyone else runs into this problem, here is how I resolved it. 
Essentially, Eclipse has trouble importing multi-module Maven projects.

First, I discovered that there was a hidden alert dialog underneath the
restart Eclipse popup when I imported the project.  It read:
An internal error occurred during: "Updating Maven Project".  Unsupported
IClasspathEntry kind=4

There are various suggestions of how to fix this in online posts, such as:
http://thetechnodyne.blogspot.com/2012/09/fixing-error-importing-maven.html
Unfortunately, once you get this error, various .classpath files start to
become corrupted, and Eclipse becomes more and more confused, and so none of
these fixes worked for me

I deleted the projects from Eclipse.  I then manually searched and removed
all Eclipse-related resources in all subdirectories, including .classpath
and .project files and .settings subdirectories.  Then I reimported
everything fresh into Eclipse.  I needed to right-click all
projects->Maven->Update Project... and then Clean and rebuild multiple
times.  Eventually, the only errors remaining are a few actual Java
problems:

These I am not going to worry about.





--
View this message in context: http://shiro-user.582556.n2.nabble.com/How-to-fix-Shiro-errors-in-Eclipse-tp7578835p7578842.html
Sent from the Shiro User mailing list archive at Nabble.com.

Re: How to fix Shiro errors in Eclipse?

Posted by "richard@localmed.com" <ri...@localmed.com>.
I am currently wondering if the incompatibilities listed here might be the
source of the problem:
http://maven.apache.org/release-notes-3.x.html




--
View this message in context: http://shiro-user.582556.n2.nabble.com/How-to-fix-Shiro-errors-in-Eclipse-tp7578835p7578838.html
Sent from the Shiro User mailing list archive at Nabble.com.

Re: How to fix Shiro errors in Eclipse?

Posted by "richard@localmed.com" <ri...@localmed.com>.
Yes, I have tried Update Project.  I've also tried Refresh, Clean, restarting
Eclipse, deleting and re-importing the project from scratch....all no luck.



--
View this message in context: http://shiro-user.582556.n2.nabble.com/How-to-fix-Shiro-errors-in-Eclipse-tp7578835p7578837.html
Sent from the Shiro User mailing list archive at Nabble.com.