public static function reloadDefinitions($config) {
		// Load default commands definitions
		$result = self::reloadFileDefinitions ( __DIR__ . "/commands_definition.json" );
		if ($result) {
			self::$log->debug ( "CommandFactory: default commands_definition.json loaded" );
		} else {
			self::$log->error ( "CommandFactory: Error loading default commands_definition.json, check json format or file permissions." );
		}
		
		// Load custom commands definitions
		$filename = $config->custom_cmds;
		$result = self::reloadFileDefinitions ( $filename, FALSE );
		if ($result) {
			self::$log->debug ( "CommandFactory: custom commands $filename loaded" );
		} else {
			self::$log->warning ( "CommandFactory: Warning . Could not load custom commands from $filename, check json format or file permissions." );
		}
		
		self::$log->debug ( "CommandFactory: Loaded " . count ( self::$commands ) . " commands." );
		$commandKeys = array_keys ( self::$commands );
		self::$log->debug ( "CommandFactory: Available commands: " . implode ( ", ", $commandKeys ) );
	}