WordPress.org

Make WordPress Core

Opened 8 years ago

Closed 8 years ago

Last modified 7 years ago

#12672 closed enhancement (fixed)

Provide Multisite stats to api.wordpress.org

Reported by: josephscott Owned by: josephscott
Milestone: 3.0 Priority: normal
Severity: normal Version: 3.0
Component: Multisite Keywords: has-patch commit
Focuses: Cc:

Description

WPMU provided additional stats to api.wordpress.org, specifically the number of blogs and users. WP3.0 should provide this as well. In addition a simple indicator if multisite is turned on or not would be helpful.

This is also a good chance to clear up some confusing items that were in WPMU. When doing a version check against api.wordpress.org WPMU didn't indicate if the check was happening from the main install blog, or one of the additional created blogs. This made it impossible to tell if there were multiple installs on the same domain/site or if it they were just several blogs that were all part of one install. To deal with this I'm suggesting we provide 'wp_install' (the main WP install URL) and 'wp_blog' (the URL for the blog being used, could be part of a multisite install) when doing the version check.

I'm including a simple patch to provide these data points. We may also want to bump the version number for the update check URL to 1.5. If we end up doing that I can make the change on the api.wordpress.org side.

Attachments (4)

wp-includes--update.php.diff (1.5 KB) - added by josephscott 8 years ago.
12672.2.diff (1.4 KB) - added by wpmuguru 8 years ago.
12672.3.diff (1.4 KB) - added by josephscott 8 years ago.
12672.4.diff (1.5 KB) - added by josephscott 8 years ago.
minor spacing clean up, use home_url() for the user-agent as well

Download all attachments as: .zip

Change History (21)

#1 @TobiasBg
8 years ago

  • Cc wordpress@… added

#2 @Denis-de-Bernardy
8 years ago

I don't mean to bring privacy issues back to the front lines, but... as much as I can vaguely picture the number of sites to be a useful piece of data, it is positively none of wp.org's business to know how many users are on a site.

Strongly suggesting wontfix until all of these stats are made public, personally. (They should have been made public a while ago, too.)

#3 @filosofo
8 years ago

Denis is right. All the arguments for collecting data and phoning it to wp.org typically center on how it's "necessary" for updates, etc. If there are such arguments for phoning back user counts, no one has yet made them.

#4 follow-up: @josephscott
8 years ago

Just as a point of reference, WPMU has been providing the user count for quite sometime. That portion is essentially a WPMU+WP30 merge item.

#5 in reply to: ↑ 4 @Denis-de-Bernardy
8 years ago

Replying to josephscott:

Just as a point of reference, WPMU has been providing the user count for quite sometime.

Yes, and the French royalty had been in charge of France until 1789. That this was the state of things until then didn't make it any more legit.

Quite honestly, and per my comment in wp-devel, I think the key issue goes down to whether these stats are made public. At the moment, they aren't. Imo, all stats collection should be removed until they are.

#6 @dd32
8 years ago

I don't think theres a need to send the Site and Network URL's, a simple boolean will suffice to differentiate the request?

I'd prefer to see all these vars passed via POST instead of GET and custom headers, but i'm assuming this is for Caching purposes..

#7 @dd32
8 years ago

but i'm assuming this is for Caching purposes..

Which would be next to useless i think for stats collection, as the scripts need to parse the passed information in order to store them, so GET/POST/Headers, it'll have all that information regardless.

@wpmuguru
8 years ago

#8 @wpmuguru
8 years ago

The network_site_url() part of 12672.2.diff is due to the fact that not all existing MU installs have DOMAIN_CURRENT_SITE & PATH_CURRENT_SITE defined. I added the other change to see if that was more agreeable.

@josephscott
8 years ago

#9 @josephscott
8 years ago

Updated patch

  • moved count_users() out of the multisite conditional
  • use home_url()

@josephscott
8 years ago

minor spacing clean up, use home_url() for the user-agent as well

#10 @nacin
8 years ago

  • Keywords commit added
  • Owner set to josephscott
  • Status changed from new to assigned

#11 @wpmuguru
8 years ago

This patch is waiting for work to be completed on the api.wordpress.org side before being committed.

#12 @josephscott
8 years ago

(In [14010]) Update stats provided to api.wordpress.org see #12672

#13 follow-up: @nacin
8 years ago

get_bloginfo('url') == home_url(), not home_url('/'). Just checking to see whether this would affect your stats collection.

#14 in reply to: ↑ 13 @josephscott
8 years ago

Replying to nacin:

get_bloginfo('url') == home_url(), not home_url('/'). Just checking to see whether this would affect your stats collection.

I assume you are referring to the user-agent item. I changed it to be consistent with the other items. Since this was just the user-agent being sent to api.wordpress.org I figured it was safe.

#15 @Denis-de-Bernardy
8 years ago

if r14010 doesn't get reversed, expect a huge amount of FUD. Just saying...

#16 @nacin
8 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

#17 @hakre
7 years ago

Related: #16778

Note: See TracTickets for help on using tickets.