17.04.2023 13:36, Vlad Khorsun wrote:
>
>> As these files are huge now, I'm thinking in split them in specific
>> files per each node in a subdirectory after v5 branch is forked or v5
>> final is released.
>>
>> Advantages:
>> - Better organization
>> - Easy to work with specific node
>>
>> Disadvantages:
>> - Hard to do bulk refactors
>> - More difficult to backport changes between the versions
>>
>> What do you think?
>
> I, personally, prefer to not follow file-per-class approach.
> I consider it as not less bad as all classes in one file.
As for me, having 100500 classes inside one file is pretty much the same
PITA as having 100500 files inside the directory.
> Could we split existing nodes (classes) on some smaller logical coupled
> groups ?
This could be a good compromise. Alternatively, we may have
one-class-per-file, but split the files between sub-directories, e.g.
using your naming:
/dsql/PSqlNodes
/dsql/DmlNodes
/dsql/SessionNodes
/dsql/TransactionNodes
(maybe omitting the Nodes suffix)
Yes, backporting will require manual changes instead of cherry-picking,
but this is how we lived before Git, so this is surely not the end of
the world.
Dmitry