import solr source to eclipse

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

import solr source to eclipse

Ali Nazemian
Hi,
I am going to import solr source code to eclipse for some development
purpose. Unfortunately every tutorial that I found for this purpose is
outdated and did not work. So would you please give me some hint about how
can I import solr source code to eclipse?
Thank you very much.

--
A.Nazemian
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Anurag Sharma
I recently tried to run eclipse in debug mode and followed
http://wiki.apache.org/solr/HowToConfigureEclipse. It worked for me.


On Sun, Oct 12, 2014 at 7:39 PM, Ali Nazemian <[hidden email]> wrote:

> Hi,
> I am going to import solr source code to eclipse for some development
> purpose. Unfortunately every tutorial that I found for this purpose is
> outdated and did not work. So would you please give me some hint about how
> can I import solr source code to eclipse?
> Thank you very much.
>
> --
> A.Nazemian
>
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Tomás Fernández Löbbe
In reply to this post by Ali Nazemian
The way I do this:
From a terminal:
svn checkout https://svn.apache.org/repos/asf/lucene/dev/trunk/
lucene-solr-trunk
cd lucene-solr-trunk
ant eclipse

... And then, from your Eclipse "import existing java project", and select
the directory where you placed lucene-solr-trunk

On Sun, Oct 12, 2014 at 7:09 AM, Ali Nazemian <[hidden email]> wrote:

> Hi,
> I am going to import solr source code to eclipse for some development
> purpose. Unfortunately every tutorial that I found for this purpose is
> outdated and did not work. So would you please give me some hint about how
> can I import solr source code to eclipse?
> Thank you very much.
>
> --
> A.Nazemian
>
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Rajinimaski
Hi,

The best tutorial for setting up Solr[solr 4.7] in eclipse/intellij  is
documented in Solr In Action book, Apendix A, *Working with the Solr
codebase*


On Mon, Oct 13, 2014 at 6:45 AM, Tomás Fernández Löbbe <
[hidden email]> wrote:

> The way I do this:
> From a terminal:
> svn checkout https://svn.apache.org/repos/asf/lucene/dev/trunk/
> lucene-solr-trunk
> cd lucene-solr-trunk
> ant eclipse
>
> ... And then, from your Eclipse "import existing java project", and select
> the directory where you placed lucene-solr-trunk
>
> On Sun, Oct 12, 2014 at 7:09 AM, Ali Nazemian <[hidden email]>
> wrote:
>
> > Hi,
> > I am going to import solr source code to eclipse for some development
> > purpose. Unfortunately every tutorial that I found for this purpose is
> > outdated and did not work. So would you please give me some hint about
> how
> > can I import solr source code to eclipse?
> > Thank you very much.
> >
> > --
> > A.Nazemian
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Ali Nazemian
Thank you very much for your guides but how can I run solr server inside
eclipse?
Best regards.

On Mon, Oct 13, 2014 at 8:02 PM, Rajani Maski <[hidden email]> wrote:

> Hi,
>
> The best tutorial for setting up Solr[solr 4.7] in eclipse/intellij  is
> documented in Solr In Action book, Apendix A, *Working with the Solr
> codebase*
>
>
> On Mon, Oct 13, 2014 at 6:45 AM, Tomás Fernández Löbbe <
> [hidden email]> wrote:
>
> > The way I do this:
> > From a terminal:
> > svn checkout https://svn.apache.org/repos/asf/lucene/dev/trunk/
> > lucene-solr-trunk
> > cd lucene-solr-trunk
> > ant eclipse
> >
> > ... And then, from your Eclipse "import existing java project", and
> select
> > the directory where you placed lucene-solr-trunk
> >
> > On Sun, Oct 12, 2014 at 7:09 AM, Ali Nazemian <[hidden email]>
> > wrote:
> >
> > > Hi,
> > > I am going to import solr source code to eclipse for some development
> > > purpose. Unfortunately every tutorial that I found for this purpose is
> > > outdated and did not work. So would you please give me some hint about
> > how
> > > can I import solr source code to eclipse?
> > > Thank you very much.
> > >
> > > --
> > > A.Nazemian
> > >
> >
>



--
A.Nazemian
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Rajinimaski
Configure eclipse with Jetty plugin. Create a Solr folder under your
Solr-Java-Project and Run the project [Run as] on Jetty Server.

This blog[1] may help you to configure Solr within eclipse.


[1]
http://hokiesuns.blogspot.in/2010/01/setting-up-apache-solr-in-eclipse.html

On Tue, Oct 14, 2014 at 12:06 PM, Ali Nazemian <[hidden email]>
wrote:

> Thank you very much for your guides but how can I run solr server inside
> eclipse?
> Best regards.
>
> On Mon, Oct 13, 2014 at 8:02 PM, Rajani Maski <[hidden email]>
> wrote:
>
> > Hi,
> >
> > The best tutorial for setting up Solr[solr 4.7] in eclipse/intellij  is
> > documented in Solr In Action book, Apendix A, *Working with the Solr
> > codebase*
> >
> >
> > On Mon, Oct 13, 2014 at 6:45 AM, Tomás Fernández Löbbe <
> > [hidden email]> wrote:
> >
> > > The way I do this:
> > > From a terminal:
> > > svn checkout https://svn.apache.org/repos/asf/lucene/dev/trunk/
> > > lucene-solr-trunk
> > > cd lucene-solr-trunk
> > > ant eclipse
> > >
> > > ... And then, from your Eclipse "import existing java project", and
> > select
> > > the directory where you placed lucene-solr-trunk
> > >
> > > On Sun, Oct 12, 2014 at 7:09 AM, Ali Nazemian <[hidden email]>
> > > wrote:
> > >
> > > > Hi,
> > > > I am going to import solr source code to eclipse for some development
> > > > purpose. Unfortunately every tutorial that I found for this purpose
> is
> > > > outdated and did not work. So would you please give me some hint
> about
> > > how
> > > > can I import solr source code to eclipse?
> > > > Thank you very much.
> > > >
> > > > --
> > > > A.Nazemian
> > > >
> > >
> >
>
>
>
> --
> A.Nazemian
>
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Anurag Sharma
Another alternative is launch the jetty server from outside and attach it
remotely from eclipse.

java -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=7666
-jar start.jar
The above command waits until the application attach succeed.


On Tue, Oct 14, 2014 at 12:56 PM, Rajani Maski <[hidden email]>
wrote:

> Configure eclipse with Jetty plugin. Create a Solr folder under your
> Solr-Java-Project and Run the project [Run as] on Jetty Server.
>
> This blog[1] may help you to configure Solr within eclipse.
>
>
> [1]
> http://hokiesuns.blogspot.in/2010/01/setting-up-apache-solr-in-eclipse.html
>
> On Tue, Oct 14, 2014 at 12:06 PM, Ali Nazemian <[hidden email]>
> wrote:
>
> > Thank you very much for your guides but how can I run solr server inside
> > eclipse?
> > Best regards.
> >
> > On Mon, Oct 13, 2014 at 8:02 PM, Rajani Maski <[hidden email]>
> > wrote:
> >
> > > Hi,
> > >
> > > The best tutorial for setting up Solr[solr 4.7] in eclipse/intellij  is
> > > documented in Solr In Action book, Apendix A, *Working with the Solr
> > > codebase*
> > >
> > >
> > > On Mon, Oct 13, 2014 at 6:45 AM, Tomás Fernández Löbbe <
> > > [hidden email]> wrote:
> > >
> > > > The way I do this:
> > > > From a terminal:
> > > > svn checkout https://svn.apache.org/repos/asf/lucene/dev/trunk/
> > > > lucene-solr-trunk
> > > > cd lucene-solr-trunk
> > > > ant eclipse
> > > >
> > > > ... And then, from your Eclipse "import existing java project", and
> > > select
> > > > the directory where you placed lucene-solr-trunk
> > > >
> > > > On Sun, Oct 12, 2014 at 7:09 AM, Ali Nazemian <[hidden email]
> >
> > > > wrote:
> > > >
> > > > > Hi,
> > > > > I am going to import solr source code to eclipse for some
> development
> > > > > purpose. Unfortunately every tutorial that I found for this purpose
> > is
> > > > > outdated and did not work. So would you please give me some hint
> > about
> > > > how
> > > > > can I import solr source code to eclipse?
> > > > > Thank you very much.
> > > > >
> > > > > --
> > > > > A.Nazemian
> > > > >
> > > >
> > >
> >
> >
> >
> > --
> > A.Nazemian
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Erick Erickson
I do exactly what Anurag mentioned, but _only_ when what
I want to debug is, for some reason, not accessible via unit
tests. It's very easy to do.

It's usually much faster though to use unit tests, which you
should be able to run from eclipse without starting a server
at all. In IntelliJ, you just ctrl-click on the file and the menu
gives you a choice of running or debugging the unit test, I'm
sure Eclipse does something similar.

There are zillions of units to choose from, and for new development
it's a Good Thing to write the unit test first...

Good luck!
Erick

On Tue, Oct 14, 2014 at 1:37 AM, Anurag Sharma <[hidden email]> wrote:

> Another alternative is launch the jetty server from outside and attach it
> remotely from eclipse.
>
> java -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=7666
> -jar start.jar
> The above command waits until the application attach succeed.
>
>
> On Tue, Oct 14, 2014 at 12:56 PM, Rajani Maski <[hidden email]>
> wrote:
>
>> Configure eclipse with Jetty plugin. Create a Solr folder under your
>> Solr-Java-Project and Run the project [Run as] on Jetty Server.
>>
>> This blog[1] may help you to configure Solr within eclipse.
>>
>>
>> [1]
>> http://hokiesuns.blogspot.in/2010/01/setting-up-apache-solr-in-eclipse.html
>>
>> On Tue, Oct 14, 2014 at 12:06 PM, Ali Nazemian <[hidden email]>
>> wrote:
>>
>> > Thank you very much for your guides but how can I run solr server inside
>> > eclipse?
>> > Best regards.
>> >
>> > On Mon, Oct 13, 2014 at 8:02 PM, Rajani Maski <[hidden email]>
>> > wrote:
>> >
>> > > Hi,
>> > >
>> > > The best tutorial for setting up Solr[solr 4.7] in eclipse/intellij  is
>> > > documented in Solr In Action book, Apendix A, *Working with the Solr
>> > > codebase*
>> > >
>> > >
>> > > On Mon, Oct 13, 2014 at 6:45 AM, Tomás Fernández Löbbe <
>> > > [hidden email]> wrote:
>> > >
>> > > > The way I do this:
>> > > > From a terminal:
>> > > > svn checkout https://svn.apache.org/repos/asf/lucene/dev/trunk/
>> > > > lucene-solr-trunk
>> > > > cd lucene-solr-trunk
>> > > > ant eclipse
>> > > >
>> > > > ... And then, from your Eclipse "import existing java project", and
>> > > select
>> > > > the directory where you placed lucene-solr-trunk
>> > > >
>> > > > On Sun, Oct 12, 2014 at 7:09 AM, Ali Nazemian <[hidden email]
>> >
>> > > > wrote:
>> > > >
>> > > > > Hi,
>> > > > > I am going to import solr source code to eclipse for some
>> development
>> > > > > purpose. Unfortunately every tutorial that I found for this purpose
>> > is
>> > > > > outdated and did not work. So would you please give me some hint
>> > about
>> > > > how
>> > > > > can I import solr source code to eclipse?
>> > > > > Thank you very much.
>> > > > >
>> > > > > --
>> > > > > A.Nazemian
>> > > > >
>> > > >
>> > >
>> >
>> >
>> >
>> > --
>> > A.Nazemian
>> >
>>
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Dan Davis-2
I had a problem with the "ant eclipse" answer - it was unable to resolve
"javax.activation" for the Javadoc.  Updating
solr/contrib/dataimporthandler-extras/ivy.xml
as follows did the trick for me:

-  <dependency org="javax.activation" name="activation"
rev="${/javax.activation/activation}" conf="compile->*"/>
+  <dependency org="javax.activation" name="activation"
rev="${/javax.activation/activation}" conf="compile->default"/>

What I'm trying to do is to construct a failing Unit test for something
that I think is a bug.   But the first thing is to be able to run tests,
probably in eclipse, but the command-line might be good enough although not
ideal.


On Tue, Oct 14, 2014 at 10:38 AM, Erick Erickson <[hidden email]>
wrote:

> I do exactly what Anurag mentioned, but _only_ when what
> I want to debug is, for some reason, not accessible via unit
> tests. It's very easy to do.
>
> It's usually much faster though to use unit tests, which you
> should be able to run from eclipse without starting a server
> at all. In IntelliJ, you just ctrl-click on the file and the menu
> gives you a choice of running or debugging the unit test, I'm
> sure Eclipse does something similar.
>
> There are zillions of units to choose from, and for new development
> it's a Good Thing to write the unit test first...
>
> Good luck!
> Erick
>
> On Tue, Oct 14, 2014 at 1:37 AM, Anurag Sharma <[hidden email]> wrote:
> > Another alternative is launch the jetty server from outside and attach it
> > remotely from eclipse.
> >
> > java -Xdebug
> -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=7666
> > -jar start.jar
> > The above command waits until the application attach succeed.
> >
> >
> > On Tue, Oct 14, 2014 at 12:56 PM, Rajani Maski <[hidden email]>
> > wrote:
> >
> >> Configure eclipse with Jetty plugin. Create a Solr folder under your
> >> Solr-Java-Project and Run the project [Run as] on Jetty Server.
> >>
> >> This blog[1] may help you to configure Solr within eclipse.
> >>
> >>
> >> [1]
> >>
> http://hokiesuns.blogspot.in/2010/01/setting-up-apache-solr-in-eclipse.html
> >>
> >> On Tue, Oct 14, 2014 at 12:06 PM, Ali Nazemian <[hidden email]>
> >> wrote:
> >>
> >> > Thank you very much for your guides but how can I run solr server
> inside
> >> > eclipse?
> >> > Best regards.
> >> >
> >> > On Mon, Oct 13, 2014 at 8:02 PM, Rajani Maski <[hidden email]>
> >> > wrote:
> >> >
> >> > > Hi,
> >> > >
> >> > > The best tutorial for setting up Solr[solr 4.7] in
> eclipse/intellij  is
> >> > > documented in Solr In Action book, Apendix A, *Working with the Solr
> >> > > codebase*
> >> > >
> >> > >
> >> > > On Mon, Oct 13, 2014 at 6:45 AM, Tomás Fernández Löbbe <
> >> > > [hidden email]> wrote:
> >> > >
> >> > > > The way I do this:
> >> > > > From a terminal:
> >> > > > svn checkout https://svn.apache.org/repos/asf/lucene/dev/trunk/
> >> > > > lucene-solr-trunk
> >> > > > cd lucene-solr-trunk
> >> > > > ant eclipse
> >> > > >
> >> > > > ... And then, from your Eclipse "import existing java project",
> and
> >> > > select
> >> > > > the directory where you placed lucene-solr-trunk
> >> > > >
> >> > > > On Sun, Oct 12, 2014 at 7:09 AM, Ali Nazemian <
> [hidden email]
> >> >
> >> > > > wrote:
> >> > > >
> >> > > > > Hi,
> >> > > > > I am going to import solr source code to eclipse for some
> >> development
> >> > > > > purpose. Unfortunately every tutorial that I found for this
> purpose
> >> > is
> >> > > > > outdated and did not work. So would you please give me some hint
> >> > about
> >> > > > how
> >> > > > > can I import solr source code to eclipse?
> >> > > > > Thank you very much.
> >> > > > >
> >> > > > > --
> >> > > > > A.Nazemian
> >> > > > >
> >> > > >
> >> > >
> >> >
> >> >
> >> >
> >> > --
> >> > A.Nazemian
> >> >
> >>
>
Reply | Threaded
Open this post in threaded view
|

Re: import solr source to eclipse

Erick Erickson
Sorry, not an Eclipse guy, I'll have to wait for them to chime in...

Kudos for trying to construct a unit test illustrating the error
though, that'll be a great help!

Erick

On Thu, Oct 16, 2014 at 4:14 PM, Dan Davis <[hidden email]> wrote:

> I had a problem with the "ant eclipse" answer - it was unable to resolve
> "javax.activation" for the Javadoc.  Updating
> solr/contrib/dataimporthandler-extras/ivy.xml
> as follows did the trick for me:
>
> -  <dependency org="javax.activation" name="activation"
> rev="${/javax.activation/activation}" conf="compile->*"/>
> +  <dependency org="javax.activation" name="activation"
> rev="${/javax.activation/activation}" conf="compile->default"/>
>
> What I'm trying to do is to construct a failing Unit test for something
> that I think is a bug.   But the first thing is to be able to run tests,
> probably in eclipse, but the command-line might be good enough although not
> ideal.
>
>
> On Tue, Oct 14, 2014 at 10:38 AM, Erick Erickson <[hidden email]>
> wrote:
>
>> I do exactly what Anurag mentioned, but _only_ when what
>> I want to debug is, for some reason, not accessible via unit
>> tests. It's very easy to do.
>>
>> It's usually much faster though to use unit tests, which you
>> should be able to run from eclipse without starting a server
>> at all. In IntelliJ, you just ctrl-click on the file and the menu
>> gives you a choice of running or debugging the unit test, I'm
>> sure Eclipse does something similar.
>>
>> There are zillions of units to choose from, and for new development
>> it's a Good Thing to write the unit test first...
>>
>> Good luck!
>> Erick
>>
>> On Tue, Oct 14, 2014 at 1:37 AM, Anurag Sharma <[hidden email]> wrote:
>> > Another alternative is launch the jetty server from outside and attach it
>> > remotely from eclipse.
>> >
>> > java -Xdebug
>> -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=7666
>> > -jar start.jar
>> > The above command waits until the application attach succeed.
>> >
>> >
>> > On Tue, Oct 14, 2014 at 12:56 PM, Rajani Maski <[hidden email]>
>> > wrote:
>> >
>> >> Configure eclipse with Jetty plugin. Create a Solr folder under your
>> >> Solr-Java-Project and Run the project [Run as] on Jetty Server.
>> >>
>> >> This blog[1] may help you to configure Solr within eclipse.
>> >>
>> >>
>> >> [1]
>> >>
>> http://hokiesuns.blogspot.in/2010/01/setting-up-apache-solr-in-eclipse.html
>> >>
>> >> On Tue, Oct 14, 2014 at 12:06 PM, Ali Nazemian <[hidden email]>
>> >> wrote:
>> >>
>> >> > Thank you very much for your guides but how can I run solr server
>> inside
>> >> > eclipse?
>> >> > Best regards.
>> >> >
>> >> > On Mon, Oct 13, 2014 at 8:02 PM, Rajani Maski <[hidden email]>
>> >> > wrote:
>> >> >
>> >> > > Hi,
>> >> > >
>> >> > > The best tutorial for setting up Solr[solr 4.7] in
>> eclipse/intellij  is
>> >> > > documented in Solr In Action book, Apendix A, *Working with the Solr
>> >> > > codebase*
>> >> > >
>> >> > >
>> >> > > On Mon, Oct 13, 2014 at 6:45 AM, Tomás Fernández Löbbe <
>> >> > > [hidden email]> wrote:
>> >> > >
>> >> > > > The way I do this:
>> >> > > > From a terminal:
>> >> > > > svn checkout https://svn.apache.org/repos/asf/lucene/dev/trunk/
>> >> > > > lucene-solr-trunk
>> >> > > > cd lucene-solr-trunk
>> >> > > > ant eclipse
>> >> > > >
>> >> > > > ... And then, from your Eclipse "import existing java project",
>> and
>> >> > > select
>> >> > > > the directory where you placed lucene-solr-trunk
>> >> > > >
>> >> > > > On Sun, Oct 12, 2014 at 7:09 AM, Ali Nazemian <
>> [hidden email]
>> >> >
>> >> > > > wrote:
>> >> > > >
>> >> > > > > Hi,
>> >> > > > > I am going to import solr source code to eclipse for some
>> >> development
>> >> > > > > purpose. Unfortunately every tutorial that I found for this
>> purpose
>> >> > is
>> >> > > > > outdated and did not work. So would you please give me some hint
>> >> > about
>> >> > > > how
>> >> > > > > can I import solr source code to eclipse?
>> >> > > > > Thank you very much.
>> >> > > > >
>> >> > > > > --
>> >> > > > > A.Nazemian
>> >> > > > >
>> >> > > >
>> >> > >
>> >> >
>> >> >
>> >> >
>> >> > --
>> >> > A.Nazemian
>> >> >
>> >>
>>