13 Replies Latest reply on Nov 7, 2008 6:19 PM by mazz

    eclipse project files

    starksm64

      Do you typically include the eclipse .project/.classpath or generate those via mvn eclipse:eclipse?

        • 1. Re: eclipse project files
          mazz

          we include them - at least we do in the RHQ and Jopr project. If they do not yet exist for emb jopr, we need to check them in.

          • 2. Re: eclipse project files
            starksm64

            They are not there for embjopr. I had to generate them.

            • 3. Re: eclipse project files
              mazz

              I'll see if I can check something in. Ian is going to look into publishing the -src jars on the snapshot repo, so I'll have eclipse dependencies on the local maven repo with source dependencies from there too.

              The other alternative is to have the eclipse embjopr project have a dependency on the rhq project, but that would require the dev to svn co the RHQ trunk, not something I don't think we want embjopr devs to have to do.

              • 4. Re: eclipse project files
                mazz

                I checked in a .classpath and .project at trunk level.

                These are going in the top level, even though technically we could/should have subprojects for the jbas4 and jbas5 modules (since they probably will have very different dependencies). That's how mvn eclipse:eclipse produces them - but, that would require the developer to create multiple projects within eclipse and its annoying to manage these.

                So for now, since its easier/quicker for a new developer to get started this way (and because we build the actual project using mvn at command line anyway) these are here at the top level. This will allow eclipse to compile the code and look/edit source today.

                In the future, if the need arises, we can break this out into separate subprojects (and sub .classpath/.project files) so the jbas5 and jbas4 modules can have different dependencies.

                • 5. Re: eclipse project files
                  ips

                  Source and javadoc jars are now published to the snapshot repo [1] and will be updated nightly at 5am by Hudson.

                  To include the source and javadoc jars in your Maven-generated IntelliJ or Eclipse project, use:

                  mvn -DdownloadJavadocs=true -DdownloadSources=true idea:idea
                  

                  or:

                  mvn -DdownloadJavadocs=true -DdownloadSources=true eclipse:eclipse


                  [1]
                  http://snapshots.jboss.org/maven2/org/rhq/
                  http://snapshots.jboss.org/maven2/org/jboss/on/



                  • 6. Re: eclipse project files
                    mazz

                    Oh, and right now, there is no source attached to the rhq dependencies since they are not yet published. once they are published, we can add the source locations to .classpath.

                    • 7. Re: eclipse project files
                      starksm64

                      Ok, great, source attachments was going to be my next question ;)

                      • 8. Re: eclipse project files
                        mazz

                        I spoke to soon :)

                        I'll get those into the .classpath now.

                        • 9. Re: eclipse project files
                          mazz

                          OK, I checked in a new .classpath that attaches available source to the dependencies - including RHQ dependencies.

                          BTW: I had a problem pulling down the new sources since Ian just uploaded them - if you have problems, pass the -U option to mvn - that forces it to pull them down.

                          • 10. Re: eclipse project files
                            starksm64

                            I'm down to just one error in the eclipse projects of rhq:

                            Severity and Description Path Resource Location Creation Time Id
                            Project 'rhq' is missing required library: '/home/svn/repository.jboss.org/maven2/net/sf/bluecove/bluecove/2.0.1/bluecove-2.0.1.jar' rhq Build path 1226097738043 463
                            


                            but does not appear to be in any poms, so was not pulled down during the mvn build which did succeed:
                            [650][valkyrie: rhq]$ grep -r bluecove-2.0.1.jar .
                            ./.classpath: <classpathentry exported="true" kind="var" path="M2_REPO/net/sf/bluecove/bluecove/2.0.1/bluecove-2.0.1.jar"/>
                            ./.svn/text-base/.classpath.svn-base: <classpathentry exported="true" kind="var" path="M2_REPO/net/sf/bluecove/bluecove/2.0.1/bluecove-2.0.1.jar"/>
                            [651][valkyrie: rhq]$
                            


                            The jar is needed as if I remove it there are compile errors in the BluetoothDeviceComponent.


                            • 11. Re: eclipse project files
                              mazz

                              I swear I want to completely delete that Bluetooth plugin :)

                              If you cd to modules/plugins/bluetooth and "mvn -Dmaven.test.skip install" from there, that dependency should pull down. We took out the bluetooth plugin from the default maven reactor so it won't build unless you explicitly do so from the bluetooth module directory.

                              We discussed in the past getting rid of that plugin entirely, but figured if someone wants to come along and adopt it, they can.

                              • 12. Re: eclipse project files
                                starksm64

                                Ok, I now have jopr, embjopr, and rhq projects cleanly loaded into eclipse.
                                Thanks.

                                • 13. Re: eclipse project files
                                  mazz

                                  FYI, I just created:

                                  http://jira.rhq-project.org/browse/RHQ-1085

                                  regarding the bluetooth plugin issue.