[buddypress-trac] [BuddyPress Trac] #6413: xprofile fielddata visibility should be stored in xprofilemeta

buddypress-trac noreply at wordpress.org
Thu Jan 21 04:43:35 UTC 2016


#6413: xprofile fielddata visibility should be stored in xprofilemeta
----------------------------------+---------------------------
 Reporter:  boonebgorges          |       Owner:  boonebgorges
     Type:  defect (bug)          |      Status:  assigned
 Priority:  normal                |   Milestone:  2.5
Component:  Component - XProfile  |     Version:
 Severity:  normal                |  Resolution:
 Keywords:  2nd-opinion           |
----------------------------------+---------------------------
Changes (by boonebgorges):

 * keywords:   => 2nd-opinion


Comment:

 [attachment:6413.diff] is a partial pass at the modifications to xprofile,
 along with the necessary migration routine. I still have to adapt the
 logic of hiding fields based on visibility in `BP_XProfile_Group`.

 I wanted to post the partial patch because I'm not feeling very good about
 how the migration will work. In [attachment:6413.diff], I've used a cron
 technique: during upgrade, a cron job is scheduled, which will run every
 minute until the callback detects that the migration is done. It's
 currently migrating 25 users at a time. This number could be increased,
 but not, I think, by very much. Even at 100 per batch, it could take hours
 for large sites to be migrated. This seems bad. On the other hand, if we
 don't use wp-cron, then we need to either:

 a. come up with either a UI (like: click a button, fire an AJAX request,
 see the progress in a progressbar, try to support no-js? etc) or,
 b. come up with some new technique for background processes. Maybe
 loopback requests (which wouldn't have to wait a full minute like our cron
 job) or maybe something like https://deliciousbrains.com/background-
 processing-wordpress/

 This particular migration routine is not the only place where this issue
 will arise in the future. Moving Favorites to a relationship table seems
 like another place where the load may be too large to do in a single
 batch. So let's come up with a strategy that we can reuse in the future.

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6413#comment:5>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list