 956c4058e6
			
		
	
	956c4058e6
	
	
	
		
			
			Summary:
Ref T13060. See PHI343. Triaging this bug required figuring out where in the pipeline UTF8 was being dropped, and bisecting the pipeline required making calls to Conduit.
Currently, there's no easy way to debug/inspect arbitrary Conduit calls, especially when they are `diffusion.*` calls which route to a different host (even if you have a real session and use the web console for these, you just see an HTTP service call to the target host in DarkConsole).
Add a `bin/conduit` utility to make this kind of debugging easier, with an eye toward the Phacility production cluster (or other similar clusters) specifically.
Test Plan:
  - Ran `echo '{}' | bin/conduit call --method conduit.ping --input -` and similar.
  - Used a similar approach to successfully diagnose the UTF8 issue in T13060.
Reviewers: amckinley
Reviewed By: amckinley
Maniphest Tasks: T13060
Differential Revision: https://secure.phabricator.com/D18987
		
	
		
			
				
	
	
		
			22 lines
		
	
	
		
			552 B
		
	
	
	
		
			PHP
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			22 lines
		
	
	
		
			552 B
		
	
	
	
		
			PHP
		
	
	
		
			Executable File
		
	
	
	
	
| #!/usr/bin/env php
 | |
| <?php
 | |
| 
 | |
| $root = dirname(dirname(dirname(__FILE__)));
 | |
| require_once $root.'/scripts/init/init-script.php';
 | |
| 
 | |
| $args = new PhutilArgumentParser($argv);
 | |
| $args->setTagline(pht('manage Conduit'));
 | |
| $args->setSynopsis(<<<EOSYNOPSIS
 | |
| **conduit** __command__ [__options__]
 | |
|     Manage Conduit.
 | |
| 
 | |
| EOSYNOPSIS
 | |
|   );
 | |
| $args->parseStandardArguments();
 | |
| 
 | |
| $workflows = id(new PhutilClassMapQuery())
 | |
|   ->setAncestorClass('PhabricatorConduitManagementWorkflow')
 | |
|   ->execute();
 | |
| $workflows[] = new PhutilHelpArgumentWorkflow();
 | |
| $args->parseWorkflows($workflows);
 |