@mock<EOL><INDENT>def _invoke_internal(self, function_arn, payload, client_context, invocation_type="<STR_LIT>"):<DEDENT>
customer_logger.info('<STR_LIT>'.format(function_arn, payload))<EOL>try:<EOL><INDENT>invocation_id = self.ipc.post_work(function_arn, payload, client_context, invocation_type)<EOL>if invocation_type == "<STR_LIT>":<EOL><INDENT>return {'<STR_LIT>': b'<STR_LIT>', '<STR_LIT>': '<STR_LIT>'}<EOL><DEDENT>work_result_output = self.ipc.get_work_result(function_arn, invocation_id)<EOL>if not work_result_output.func_err:<EOL><INDENT>output_payload = StreamingBody(work_result_output.payload)<EOL><DEDENT>else:<EOL><INDENT>output_payload = work_result_output.payload<EOL><DEDENT>invoke_output = {<EOL>'<STR_LIT>': output_payload,<EOL>'<STR_LIT>': work_result_output.func_err,<EOL>}<EOL>return invoke_output<EOL><DEDENT>except IPCException as e:<EOL><INDENT>customer_logger.exception(e)<EOL>raise InvocationException('<STR_LIT>' + str(e))<EOL><DEDENT>
This private method is seperate from the main, public invoke method so that other code within this SDK can
give this Lambda client a raw payload/client context to invoke with, rather than having it built for them.
This lets you include custom ExtensionMap_ values like subject which are needed for our internal pinned Lambdas.