code: def _fits_ws_close_msg(msg: str):
      # Websocket close messages ('reasons') can't exceed 123 bytes:
      # https://developer.mozilla.org/en-US/docs/Web/API/WebSocket/close
      ws_closing_msg_max_len = 123
      return len(msg.encode("utf-8")) <= ws_closing_msg_max_len
  
file_path: jina/jina/serve/runtimes/gateway/websocket_fastapi_app.py
imports: from typing import TYPE_CHECKING, Any, AsyncIterator, Dict, List, Optional, Union
  from jina._docarray import docarray_v2
  from jina.clients.request import request_generator
  from jina.enums import DataInputType, WebsocketSubProtocols
  from jina.excepts import InternalNetworkError
  from jina.helper import get_full_version
  from jina.importer import ImportExtensions
  from jina.logging.logger import JinaLogger
  from jina.types.request.data import DataRequest
  from jina.types.request.status import StatusMessage
label_desc: Use image node_id 1 for calling a global function with example usage: _fits_ws_close_msg(msg) and returns: unknown