def scale(self, quantity):
        """Scales the given process to the given number of dynos."""

        r = self._h._http_resource(
            method='POST',
            resource=('apps', self.app.name, 'ps', 'scale'),
            data={'type': self.type, 'qty': quantity}
        )

        r.raise_for_status()

        try:
            return self.app.processes[self.type]
        except KeyError:
            return ProcessListResource()
def scale ( self , quantity ) : r = self . _h . _http_resource ( method = 'POST' , resource = ( 'apps' , self . app . name , 'ps' , 'scale' ) , data = { 'type' : self . type , 'qty' : quantity } ) r . raise_for_status ( ) try : return self . app . processes [ self . type ] except KeyError : return ProcessListResource ( )
Scales the given process to the given number of dynos.