internal 1.1.28__tar.gz → 1.1.28b0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of internal might be problematic. Click here for more details.
- {internal-1.1.28 → internal-1.1.28b0}/PKG-INFO +1 -1
- {internal-1.1.28 → internal-1.1.28b0}/pyproject.toml +1 -1
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/const.py +4 -9
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/middleware/log_request.py +8 -2
- {internal-1.1.28 → internal-1.1.28b0}/README.md +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/base_config.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/base_factory.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/cache_redis.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/car_relation_type.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/description_type.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/device_code.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/event_code.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/lpr_direction.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/notify_type.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/operator_type.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/order_type.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/common_enum/websocket_channel.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/database.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/exception/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/exception/app_exception.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/exception/base_exception.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/exception/internal_exception.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/ext/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/ext/amazon/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/ext/amazon/aws/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/ext/amazon/aws/const.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/http/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/http/requests.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/http/responses.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/interface/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/interface/base_interface.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/middleware/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/model/__init__.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/model/base_model.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/model/operate.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/utils.py +0 -0
- {internal-1.1.28 → internal-1.1.28b0}/src/internal/validator_utils.py +0 -0
|
@@ -44,12 +44,7 @@ REDIS_LPR_DATA_LIST_PREFIX = "lpr_data_list"
|
|
|
44
44
|
|
|
45
45
|
CORRELATION_ID_HEADER_KEY_NAME = "X-Request-ID"
|
|
46
46
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
SOURCE_CUSTOMER_BY_SMART_WORKSHOP_IMPORTED_SERVICE_TICKET = 'CustomerBySmartWorkshopImportedServiceTicket'
|
|
53
|
-
SOURCE_CUSTOMER_BY_SMART_WORKSHOP_IMPORTED_DMS_DATA = 'CustomerBySmartWorkshopImportedDMSData'
|
|
54
|
-
SOURCE_CUSTOMER_BY_WEBHOOK = 'CustomerByWebhook'
|
|
55
|
-
SOURCE_CUSTOMER_BY_SMART_WORKSHOP = 'CustomerBySmartWorkshopManual'
|
|
47
|
+
SOURCE_SMART_WORKSHOP_IMPORTED_SERVICE_TICKET = 'SmartWorkshopImportedServiceTicket'
|
|
48
|
+
SOURCE_SMART_WORKSHOP_IMPORTED_DMS_DATA = 'SmartWorkshopImportedDMSData'
|
|
49
|
+
SOURCE_WEBHOOK = 'Webhook'
|
|
50
|
+
SOURCE_SMART_WORKSHOP = 'SmartWorkshopManual'
|
|
@@ -28,12 +28,18 @@ class LogRequestMiddleware(BaseHTTPMiddleware):
|
|
|
28
28
|
params = {k: v[0] if len(v) == 1 else v for k, v in temp.items()}
|
|
29
29
|
|
|
30
30
|
body = await request.body()
|
|
31
|
-
|
|
31
|
+
if "multipart" in headers.get("content-type"):
|
|
32
|
+
self.logger.info(f"[Request id: {request_id}] \nURL: {method} {url} \nParams: {params} \nBody: 因上傳檔案不顯示body \nHeaders: {headers} \nstart processing...")
|
|
33
|
+
else:
|
|
34
|
+
self.logger.info(f"[Request id: {request_id}] \nURL: {method} {url} \nParams: {params} \nBody: {body} \nHeaders: {headers} \nstart processing...")
|
|
32
35
|
|
|
33
36
|
# 记录请求处理时间
|
|
34
37
|
start_time = time.time()
|
|
35
38
|
response = await call_next(request)
|
|
36
39
|
process_time = time.time() - start_time
|
|
37
40
|
|
|
38
|
-
|
|
41
|
+
if "multipart" in headers.get("content-type"):
|
|
42
|
+
self.logger.info(f"[Request id: {request_id}] \nURL: {method} {url} \nParams: {params} \nBody: 因上傳檔案不顯示body \nCompleted in {process_time:.4f} seconds")
|
|
43
|
+
else:
|
|
44
|
+
self.logger.info(f"[Request id: {request_id}] \nURL: {method} {url} \nParams: {params} \nBody: {body} \nCompleted in {process_time:.4f} seconds")
|
|
39
45
|
return response
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|