MCPcopy Create free account
hub / github.com/apache/trafficserver / TSPluginInit

Function TSPluginInit

example/plugins/c-api/server_push/server_push.cc:98–114  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

96}
97
98void
99TSPluginInit(int argc ATS_UNUSED, const char *argv[] ATS_UNUSED)
100{
101 TSPluginRegistrationInfo info;
102
103 info.plugin_name = PLUGIN_NAME;
104 info.vendor_name = "Apache Software Foundation";
105 info.support_email = "dev@trafficserver.apache.org";
106
107 if (TSPluginRegister(&info) != TS_SUCCESS) {
108 TSError("[%s] Plugin registration failed", PLUGIN_NAME);
109 }
110
111 TSstrlcpy(url, argv[1], sizeof(url));
112 TSCont handler = TSContCreate(server_push_plugin, nullptr);
113 TSHttpHookAdd(TS_HTTP_SSN_START_HOOK, handler);
114}

Callers

nothing calls this directly

Calls 5

TSPluginRegisterFunction · 0.85
TSstrlcpyFunction · 0.85
TSContCreateFunction · 0.85
TSHttpHookAddFunction · 0.85
TSErrorFunction · 0.50

Tested by

no test coverage detected