Skip to content

Per project indexing missing history when checkout is in subdir #3646

Open
@fstefanov

Description

@fstefanov

Git clone in project dir

mkdir src/test
cd src/test
git clone https://github.com/oracle/opengrok.git

Add project

opengrok-projadm --base /home/ubuntu/bin/opengrok --add test
Adding project test
Added project test with repositories: ['/test/opengrok']
Refreshing configuration

Indexing

curl -s -X GET http://localhost:8080/source/api/v1/configuration -o fresh_config.xml
opengrok-indexer -a /home/ubuntu/bin/opengrok/dist/lib/opengrok.jar -- \
    -S test \
    --depth 20 \
    -c /usr/local/bin/ctags \
    -U 'http://localhost:8080/source' \
    -R fresh_config.xml \
    -H test \
    test

INFO: Indexer version 1.7.11 (939758a8e1acfde1d650a15cc94ec5653ebb4ce2) running on Java 11.0.11
Jun 23, 2021 1:33:01 PM org.opengrok.indexer.util.CtagsUtil validate
INFO: Using ctags: Universal Ctags 5.9.0(845a3ab0), Copyright (C) 2015 Universal Ctags Team
Universal Ctags is derived from Exuberant Ctags.
INFO: done invalidating 1 repositories (took 514 ms)
INFO: Done scanning for repositories, found 1 repositories (took 332 ms)
INFO: Creating historycache for 1 repositories
INFO: Done historycache for /home/ubuntu/bin/opengrok/src/test/opengrok (took 10.6 seconds)

opengrok-projadm -b ~/bin/opengrok -r
Refreshing configuration

History is missing for all files

Error: File not found!
The requested resource is not available. 

But is available under /home/ubuntu/bin/opengrok/data/historycache/test/opengrok
If i checkout opengrok.git directly under src/ dir then history is present.
This is problematic for projects like AOSP tree
I have similar issue some of the projects (not all) are missing history.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions