Talk:Collaboration/Team/Processes

Scripts and hacks
Things we do unrelated to the code in git/gerrit.

working with UUIDs
Base 36 has code to convert to/from Flow's alphadecimal representation of UUIDs in URLs e.g.  . Note JavaScript integers have insufficient precision, e.g.

There are online base36 converters, e.g. this one with ads.

mysql
We store 88-bit UUIDs in  columns, so they appear as garbled strings such as: �#�����o~p

In mysql, use  and , e.g.:

There is no (?) mysql function to convert to/from Flow's alphadecimal representation. They can be converted from alphadecimal to hex in php with the  static method.

Determining database, gaining access
The configuration of Flow's cross-wiki external database can be opaque.

ssh into MediaWiki server (e.g. deployment-bastion for the Beta cluster or terbium for production), then $ mwscript eval.php --wiki=enwiki var_dump( Flow\Container::get( 'db.factory' )->getDB( DB_SLAVE ) ); this will give you mServer, mDBname, mUser, mPassword to connect from the mysql command line.

E.g. from a labs instance to access the beta cluster, $ mysql -u mUser -p --host=mServer mDBname (enter mPassword)

Use  if you need to write to the database.

Clearing cache
Flow caches topic data which can prevent changes and fixes showing up.

If you're using memcached sudo restart memcached

If you're using redis (the default in MediaWiki-Vagrant echo flushdb | redis-cli

However, we can't do this in production. If code you introduce needs to clear the cache, instead your patch should bump. But note in production the one Flow DB is accessed by wikis running different versions of the Flow code...

Purging problem posts
If viewing a board or topic throws exception and the exception log on fluorine contains "Did not load root post UUID>", you can run ErikB's purge script on tin.eqiad.wmnet:/home/ebernhardson/purge.php. For example, if Talk:BOARDNAME on mediawiki.org has problems: Sample output Skipping mediawikiwiki:lag_times:10.64.16.18:lock Skipping mediawikiwiki:lag_times:db1038:lock Skipping mediawikiwiki:lag_times:10.64.32.18:lock Skipping mediawikiwiki:revisiontext:textid:1133331 Skipping mediawikiwiki:lag_times:10.64.16.154:lock Purging keys: flowdb:flow_workflow:title:v2::BOARDNAME:discussion:mediawikiwiki:1:4.5, flowdb:flow_topic_list:list:rvnx8zltkabnji5j:4.5, flow:tree:subtree:rvnx8zm95io4xdbb:4.5, ...

ee-flow
spage has a cron job that updates Flow and Echo, see the /etc/motd

Don't run git as root. We have git configured for group sharing, so it shouldn't be necessary. If you get permission errors, run sudo chmod -R g+w. && sudo chgrp -R project-editor-engagement.

flow-tests
flow-tests runs Labs-vagrant. There's no labs-vagrant git-update, so

to update other extensions

Beta cluster

 * remember, access through deployment-bastion.eqiad.wmflabs
 * has its own logging, wikitech:Nova_Resource:Deployment-prep/Log_Files
 * logs also available through logstash-beta

Job runner health: