Subject: Re: Any overview available on jgit codebase?

From: Farrukh Najmi <[email-masked]>
Date: Sat, 15 Nov 2008 19:21:10 -0500

Shawn O. Pearce wrote:
> Farrukh Najmi <[email-masked]> wrote:
>   
>> At minimum could anyone tell me what packages and classes to look at in  
>> order to make changes to jgit so it uses a database instead of  
>> filesystem to references.
>>     
>
> See RefDatabase, created by Repository.  You would want to replace
> RefDatabase with your own implementation, which means abstracting
> that class to be an abstract base class or an interface.
>
> RefUpdate and RefLogWriter are connected to RefDatabase, so you
> would likely need to modify those too in order to make the change,
> especially since RefUpdate is the "INSERT OR UPDATE OR DELETE"
> logic.  :)
>
> BTW, I want to do that RefDatabase abstraction anyway, because I'd
> like to get an in-memory only version of RefDatabase, to make unit
> testing easier.  So abstracting this code may be useful beyond just
> your desire to back Git with a JDBC-style database.
>   

This is just what I was hoping for. Thanks Shawn. I will try and do this 
next week and ask for help as needed. Thank you.

-- 
Regards,
Farrukh Najmi

Web: http://www.wellfleetsoftware.com