mikechengwei commented on code in PR #8254:
URL: https://github.com/apache/apisix/pull/8254#discussion_r1023450374


##########
t/APISIX.pm:
##########
@@ -506,8 +503,11 @@ _EOC_
     end
 
     require "resty.core"
-
-    $extra_init_by_lua_start
+_EOC_
+    my $calling_sub = (caller(1))[1];
+    if (index($calling_sub, "tars") != -1) {

Review Comment:
   IIUC the code, tars module `extra_init_by_lua` code need to load before 
APISIX init ,other modules `extra_init_by_lua` code  need to load after APISIX 
init.If we must remove `extra_init_by_lua_start`, we need to determine the 
execution order of `extra_init_by_lua` in a way similar to judging the module 
name.This way of displaying declarations in APISIX.pm may be more explicit.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to