I agree there is very little/unclear documentation 
on setting up history and annotation.

I finally had it WORKING! 
( I still have more work to do with IT, because some parts of
  My repository is not writable due to symlinks within repository)

I have exported cvs-server:/cvsroot ==to==>opengrok-server:/cvsroot (RW)
So that cvsroot is available locally on opengrok-server.

First I had a checked out workspace under /opt/opengrok/source
using CVSROOT=:pserver:userid at cvs-server:/auto/cvsroot
This works fine for code search/reference.
BUT History and annotate Do Not Work.

Today afternoon I created a new workspace under 
/opt/opengrok/source by checking out using 
CVSROOT=/cvsroot 
History and Annotate Do Work for this workspace!

I could get around all the export issues If I can use my CVS-Server
As opengrok server and use a local checkout by
Specifying CVSROOT=/cvsroot,
But IT policies also don't allow this.

Thanks all for responses with tips and pointers
Regards
Pranab

 
-----Original Message-----
From: opengrok-discuss-boun...@opensolaris.org
[mailto:opengrok-discuss-bounces at opensolaris.org] On Behalf Of Jim R.
Wilson
Sent: Friday, March 27, 2009 10:56 AM
To: Zach Carter
Cc: opengrok-discuss at opensolaris.org
Subject: Re: [opengrok] CVS history and annotate doesn't work

Fellow lurker here - yes, 100% on that suggestion.

I eventually got Annotation and History working on my setup.  The list
of requirements to get it working is not clearly spelled out in any
easily findable place (afaik).

In my case, I had to:
1. Ensure that a configuration.xml file was being used rather than
setting the web.xml settings (which was my first choice)
2. Set the -S and -H options, or alternatively -S and -h with
specifying the particular roots of interest, in my run.sh script
3. Ensure that the checkout path "lined up" with the specified -h paths

What I mean by #3 is that if you have a source tree that contains a
number of SVN checkouts, it's critical that the paths match what
opengrok expects to find.

So say you have an SVN repo at http://server/repo and you want to
index everything in repo/trunk/someproject

Say you plan on supporting multiple repositories, and you create a
subdirectory of your source root called "myserver-repo" and inside
that you check out "someproject".  Because the path according to the
SVN metadata is "/someproject" and the actual opengrok path is
"/myserver-repo/someproject", you'll probably find that you're getting
error messages (provided you used the -v option for verbosity)
explaining that the path has no usable history.

I eventually gave up on using history and annotate because it was
taking too long to do the initial scan, and my memory of all the hoops
I jumped through is now fading, so I apologize if any of the above is
wrong.  However I can say with certainty that setting up History and
Annotate is neither straightforward nor intuitive, and becomes
exponentially more complex if you plan to support a diverse tree of
different checkouts.

Having said all that, please note that I love OpenGrok and it's the
best source code search I've used to date.

-- Jim R. Wilson (jimbojw)

On Fri, Mar 27, 2009 at 12:21 PM, Zach Carter <z.carter at f5.com> wrote:
> I've been lurking on this list for a while and I see the same question
over
> and over, "history and annotate not working".
>
> I've also never gotten it working in my environment, probably due to
some
> quirkiness with my perforce set up.  I've given up for now, but I feel
bad for
> all those other folks having trouble out there.
>
> Is there some way that the user can get some feedback from the
application
> about why history/annotate is not working?
>
> Error messages like this would be helpful:
>
> WARNING: could not detect any source respositories, disabling
> history/annotate.
> WARNING: cvsroot not valid. disabling history/annotate.
> WARNING: disabling history/annotate because configuration not present.
>
> Any kind of feedback in the tomcat/glassfish log that tells the user
why its
> not working and points them in the right direction to fix it would be
useful,
> and it would probably save everyone a lot of time in reading and
responding to
> the same types of postings over and over.
>
> -Zach
>
>
> On Friday 27 March 2009 01:00:12 Lubos Kosco wrote:
>> Pranab Panda (pkpanda) wrote:
>> > Thanks Trond.
>> > I changed my CVSROOT=/cvsroot and reran run.sh
>> > But still History and Annotate are greyed out.
>> > Do I need to do anything.
>>
>> The question is whether you send the configuration to webapp.
>> I doubt that so I think you need to restart your tomcat or glassfish
and
>> make the web application refresh it's configuration.
>>
>> You can do above automatically without restart when using the send
>> config to webapplication option (think it's -W , check the docs or
the
>> man page)
>>
>> xing the fingers
>> Lubos
>>
>> > Please advise
>> > Pranab
>> >
>> > -----Original Message-----
>> > From: Trond.Norbye at Sun.COM [mailto:Trond.Norbye at Sun.COM]
>> > Sent: Thursday, March 26, 2009 3:27 PM
>> > To: Pranab Panda (pkpanda)
>> > Cc: Lubos.Kosco at Sun.COM; opengrok-discuss at opensolaris.org
>> > Subject: Re: [opengrok] CVS history and annotate doesn't work
>> >
>> > Pranab Panda (pkpanda) wrote:
>> >> Thanks
>> >> I have the cvstree from cvs server exported
>> >> To opengrok server and is available on opengrok server
>> >> As /cvsroot.
>> >>
>> >> I changed my CVSROOT to :local:/cvsroot
>> >
>> > Try setting it /cvsroot (remove :local: )
>> >
>> > Cheers,
>> >
>> > Trond
>> >
>> >> Then removed the indexes and reran run.sh
>> >> Redeployed source.war but still not luck.
>> >> History and Annotate are still greyed out.
>> >>
>> >> My run.sh gives the following messages
>> >> ./run.sh
>> >> Scanning for repositories...
>> >> Mar 26, 2009 2:57:09 PM
org.opensolaris.opengrok.history.HistoryGuru
>> >> addRepositories
>> >> INFO: Adding <org.opensolaris.opengrok.history.CVSRepository>
>> >> repository: </opt/opengrok/source/G/gate>
>> >> Mar 26, 2009 2:57:09 PM
org.opensolaris.opengrok.history.HistoryGuru
>> >> addRepositories
>> >> INFO: Adding <org.opensolaris.opengrok.history.CVSRepository>
>> >> repository: </opt/opengrok/source/H/gate> Mar 26, 2009 2:57:09 PM
>> >> org.opensolaris.opengrok.history.HistoryGuru addRepositories
>> >> INFO: Adding <org.opensolaris.opengrok.history.CVSRepository>
>> >> repository: </opt/opengrok/source/D/gate>
>> >> Done searching for repositories (0s)
>> >> Writing configuration to /opt/opengrok/data/configuration.xml
>> >> Done...
>> >> Mar 26, 2009 2:57:09 PM
org.opensolaris.opengrok.history.HistoryGuru
>> >> createCache
>> >> INFO: Create historycache for /opt/opengrok/source/G/gate
>> >> (CVSRepository) Mar 26, 2009 2:57:09 PM
>> >> org.opensolaris.opengrok.history.HistoryGuru createCache
>> >> INFO: Creating historycache for /opt/opengrok/source/G/gate took
(1ms)
>> >> Mar 26, 2009 2:57:09 PM
org.opensolaris.opengrok.history.HistoryGuru
>> >> createCache
>> >> INFO: Create historycache for /opt/opengrok/source/D/gate
>> >> (CVSRepository) Mar 26, 2009 2:57:09 PM
>> >> org.opensolaris.opengrok.history.HistoryGuru createCache
>> >> INFO: Creating historycache for /opt/opengrok/source/D/gate took
(0ms)
>> >> Mar 26, 2009 2:57:09 PM
org.opensolaris.opengrok.history.HistoryGuru
>> >> createCache
>> >> INFO: Create historycache for /opt/opengrok/source/H/gate
>> >> (CVSRepository) Mar 26, 2009 2:57:09 PM
>> >> org.opensolaris.opengrok.history.HistoryGuru createCache
>> >> INFO: Creating historycache for /opt/opengrok/source/H/gate took
(0ms)
>> >> Mar 26, 2009 2:57:09 PM org.opensolaris.opengrok.index.Indexer
>> >> doIndexerExecution
>> >> INFO: Starting indexExecution
>> >>
>> >> Please advise,
>> >> Thanks
>> >> Pranab
>> >>
>> >> -----Original Message-----
>> >> From: Lubos.Kosco at Sun.COM [mailto:Lubos.Kosco at Sun.COM]
>> >> Sent: Thursday, March 26, 2009 3:58 AM
>> >> To: Pranab Panda (pkpanda)
>> >> Cc: Jorgen.Austvik at Sun.COM; opengrok-discuss at opensolaris.org
>> >> Subject: Re: [opengrok] CVS history and annotate doesn't work
>> >>
>> >> Pranab Panda (pkpanda) wrote:
>> >>> Hi Jorgen
>> >>> I am using local repository and the CVSROOT is set to
>> >>>
>> >>> :pserver:accountname at servename;/path-2-cvsroot
>> >>
>> >> I guess this explains your probs as Jorgen pointed out
>> >> your CVS needs to be local for 0.7 (trunk version doesn't have
this,
>> >
>> > and
>> >
>> >> supports remote cvs, I never tested it though ;)  ;  trunk version
is
>> >
>> > a
>> >
>> >> build out of _current_ checkout of development sources )
>> >>
>> >> CVSROOT needs to be just local, e.g. /path-2-cvsroot
>> >> otherwise opengrok 0.7 will just ignore it
>> >>
>> >> once new opengrok version is out, it hopefully will not have this
>> >> restriction (although if I remember correctly, the cvs history
search
>> >> will not work, because of performance reasons, but annotate and
cvs
>> >> should work ok)
>> >>
>> >> xing the fingers
>> >> Lubos
>> >>
>> >>> My run.sh gives the following output
>> >>> ./run.sh
>> >>> Scanning for repositories...
>> >>> Mar 25, 2009 2:40:00 PM
org.opensolaris.opengrok.history.HistoryGuru
>> >>> addRepositories
>> >>> INFO: Adding <org.opensolaris.opengrok.history.CVSRepository>
>> >>> repository: </opt/opengrok/source/G/gate>
>> >>> Mar 25, 2009 2:40:00 PM
org.opensolaris.opengrok.history.HistoryGuru
>> >>> addRepositories
>> >>> INFO: Adding <org.opensolaris.opengrok.history.CVSRepository>
>> >>> repository: </opt/opengrok/source/H/gate> Mar 25, 2009 2:40:00 PM
>> >>> org.opensolaris.opengrok.history.HistoryGuru
>> >>> addRepositories
>> >>> INFO: Adding <org.opensolaris.opengrok.history.CVSRepository>
>> >>> repository: </opt/opengrok/source/D/gate>
>> >>> Done searching for repositories (0s)
>> >>> Writing configuration to /opt/opengrok/data/configuration.xml
>> >>> Done...
>> >>> Mar 25, 2009 2:40:00 PM org.opensolaris.opengrok.index.Indexer
>> >>> doIndexerExecution
>> >>> INFO: Starting indexExecution
>> >>>
>> >>> I looked at the thread about someone making changes
>> >>> To ScmChecker for cvs repository detection,
>> >>> I don't know where/how to change ScmChecker on my
>> >>> Installation and also if I need to do it since
>> >>>
>> >>> >From the outout I guess opengrok detects the cvs repository
>> >>>
>> >>> I Don't know how to use the trunk, I don't have a opensolaris
>> >>> Background. Please let me know how to do it.
>> >>>
>> >>> I had installed opengrok 0.7 in Feb 2009 so
>> >>> I assume I have the latest at that time.
>> >>>
>> >>> Please advise
>> >>> Thanks
>> >>> Pranab
>> >>> -----Original Message-----
>> >>> From: Jorgen.Austvik at Sun.COM [mailto:Jorgen.Austvik at Sun.COM]
>> >>> Sent: Wednesday, March 25, 2009 1:44 PM
>> >>> To: Pranab Panda (pkpanda)
>> >>> Cc: opengrok-discuss at opensolaris.org
>> >>> Subject: Re: [opengrok] CVS history and annotate doesn't work
>> >>>
>> >>> Pranab Panda (pkpanda) wrote:
>> >>>> The cvsroot is available on the opengrok server
>> >>>> As /cvsroot (exported from the cvsserver:/cvsroot)
>> >>>>
>> >>>> Also I have local checkouts done under
>> >>>> /opt/opengrok/source
>> >>>>
>> >>>> I scanned the mailing list archive but couldn't
>> >>>> Find anything applicable to CVS history.
>> >>>> Please advise
>> >>>
>> >>> Hi, sorry for late reply, I am at a training class at workdays
this
>> >>> week.
>> >>>
>> >>> RFE 5918 (support for history and annotations for remote CVS
>> >>> repositories) was checked in 25th of Dec, after 0.7 was released.
So
>> >
>> > I
>> >
>> >>> am trying to find out if you have a remote CVS repository (or if
>> >>> OpenGrok thinks so anyway).
>> >>>
>> >>> It looks like you are using OpenGrok 0.7, which does not support
it
>> >>
>> >> for
>> >>
>> >>> remote CVS repositories, but should support it for local CVS
>> >>> repositories.
>> >>>
>> >>> You say CVSROOT is /cvsroot, it is sometimes something like:
>> >>> :local:/cvs/repository - local repository
>> >>> :pserver:cvs at host.example.com:/cvs - remote repository
>> >>>
>> >>> The "[opengrok] Accessing RCS history local file" thread at
>> >>
>> >> "18.02.2009
>> >>
>> >>> 17:29" contains some information about that.
>> >>>
>> >>> Can you show me the console output of:
>> >>>    cat /cvsroot/CVS/Root
>> >>>    cat /cvsroot/CVS/Repository
>> >>> ?
>> >>>
>> >>> Do you have any logs of interest?
>> >>>
>> >>> Can you try with OpenGrok from trunk, to see if it is fixed
there?
>> >>>
>> >>> -J
>> >>>
>> >>>> -----Original Message-----
>> >>>> From: Jorgen.Austvik at Sun.COM [mailto:Jorgen.Austvik at Sun.COM]
>> >>>> Sent: Tuesday, March 24, 2009 12:05 AM
>> >>>> To: Pranab Panda (pkpanda)
>> >>>> Cc: opengrok-discuss at opensolaris.org
>> >>>> Subject: Re: [opengrok] CVS history and annotate doesn't work
>> >>>>
>> >>>> Pranab Panda (pkpanda) wrote:
>> >>>>> Hi
>> >>>>>
>> >>>>> Can someone please help me with CVS History and annotate issue?
>> >>>>> Thanks
>> >>>>
>> >>>> What is your CVS root?
>> >>>>
>> >>>> Have you tried to search the archives for "CVS" "history" and
>> >>>> "annotate"?
>> >>>>
>> >>>> -J
>> >>>
>> >>> _______________________________________________
>> >>> opengrok-discuss mailing list
>> >>> opengrok-discuss at opensolaris.org
>> >>> http://mail.opensolaris.org/mailman/listinfo/opengrok-discuss
>> >>
>> >> _______________________________________________
>> >> opengrok-discuss mailing list
>> >> opengrok-discuss at opensolaris.org
>> >> http://mail.opensolaris.org/mailman/listinfo/opengrok-discuss
>>
>> _______________________________________________
>> opengrok-discuss mailing list
>> opengrok-discuss at opensolaris.org
>> http://mail.opensolaris.org/mailman/listinfo/opengrok-discuss
>
> _______________________________________________
> opengrok-discuss mailing list
> opengrok-discuss at opensolaris.org
> http://mail.opensolaris.org/mailman/listinfo/opengrok-discuss
>
_______________________________________________
opengrok-discuss mailing list
opengrok-discuss at opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/opengrok-discuss

Reply via email to