In [this PR](https://github.com/localstack/localstack/pull/1200/files) we introduced a new way of starting S3 in a separate process.

In the meantime, the service startup has been significantly reworked, and it seems that we can integrate the S3 starter into the [`multiserver.py`](https://github.com/localstack/localstack/blob/master/localstack/utils/server/multiserver.py) based loading approach that loads multiple APIs in a single process, for performance reasons. We should look into that.
if isinstance(obj, dict):
            obj = dict(obj)
            for key, value in obj.items():
                if isinstance(value, BaseModel):
                    entity_id = get_entity_id(value)
                    obj[key] = entity_id or value
        return obj
    return recurse_object(resource_json, fix_ids)
def update_physical_resource_id(resource):
    phys_res_id = getattr(resource, 'physical_resource_id', None)
    if not phys_res_id:
        if isinstance(resource, lambda_models.LambdaFunction):
            func_arn = aws_stack.lambda_function_arn(resource.function_name)
            resource.function_arn = resource.physical_resource_id = func_arn
        elif isinstance(resource, sfn_models.StateMachine):
            sm_arn = aws_stack.state_machine_arn(resource.name)
            resource.physical_resource_id = sm_arn
        elif isinstance(resource, service_models.StepFunctionsActivity):
            act_arn = aws_stack.stepfunctions_activity_arn(resource.params.get('Name'))
            resource.physical_resource_id = act_arn
        elif isinstance(resource, kinesis_models.Stream):
            resource.physical_resource_id = resource.stream_name
        else:
            LOG.warning('Unable to determine physical_resource_id for resource %s' % type(resource))
def apply_patches():
    """ Apply patches to make LocalStack seamlessly interact with the moto backend.
        TODO: Eventually, these patches should be contributed to the upstream repo! """
    
    parsing.MODEL_MAP.update(MODEL_MAP)