Remove a few lookup methods in blivet.

David Lehman dlehman at redhat.com
Thu Jun 4 17:27:36 UTC 2015


On 06/04/2015 12:17 PM, Samantha N. Bueno wrote:
> On Thu, Jun 04, 2015 at 11:24:15AM -0500, David Lehman wrote:
>> On 06/04/2015 11:04 AM, Samantha N. Bueno wrote:
>>> This tiny set gets rid of a few lookup methods in blivet. There wasn't
>>> any huge advantage to them, and if you have a large number of disks on
>>> your system, all that logging kinda slowed things down a lot when you
>>> tried to do anything in the custom partitioning spoke.
>>>
>>> Also one patch to adapt anaconda to the removal of said methods, since
>>> getDevicesByType was used a few times.
>>
>> We want to plan this such that the first master build it lands in is
>> blivet-2.0 since it breaks the API. For the same reason I don't think
>> it's suitable for rhel7-branch. There we can just eliminate the
>> problematic logging or perhaps just log the names instead of the repr()
>> value.
>
> Ok, I can certainly hold off on these in master until 2.0; I'm guessing
> DeprecationWarning should be employed somehow then.

Yes, we should patch them to do that ASAP. It looks like it might take
a bit of work to get that set up. Looks like we'll need to tell the
logger to log warnings (logging.captureWarnings), adjust the
filter so that it does not ignore DeprecationWarning
(warnings.simplefilter('always', DeprecationWarning), I think), and
then issue the warning (warnings.warn).

>
> For rhel7-branch I'll try logging just the names, and hopefully that
> should still speed things up when doing custom part with a significant
> number of disks.

Works for me.

David

>
> Smantha
>
>> David
>>
>>> _______________________________________________
>>> anaconda-patches mailing list
>>> anaconda-patches at lists.fedorahosted.org
>>> https://lists.fedorahosted.org/mailman/listinfo/anaconda-patches
>>>
>>
>> _______________________________________________
>> anaconda-patches mailing list
>> anaconda-patches at lists.fedorahosted.org
>> https://lists.fedorahosted.org/mailman/listinfo/anaconda-patches
> _______________________________________________
> anaconda-patches mailing list
> anaconda-patches at lists.fedorahosted.org
> https://lists.fedorahosted.org/mailman/listinfo/anaconda-patches
>



More information about the anaconda-patches mailing list