Skip to content

Commit ba0094b

Browse files
authored
Removed appd related terminology (#245)
1 parent 6344bb8 commit ba0094b

20 files changed

+97
-125
lines changed

instrumentation/otel-webserver-module/build.gradle

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ task gypLibrary(type: Exec) {
145145
BOOST_LIB: BOOST_LIB,
146146
BOOST_INCLUDE: BOOST_INCLUDE,
147147
LIBRARY_FLAGS: libraryFlags,
148+
CPP_SDK_VERSION: cppSDKVersion,
148149
]
149150

150151
environment libraryBuildEnvironment
@@ -181,15 +182,14 @@ task stageLibrary(type: Copy) {
181182

182183
from("dist/runSDKProxy.sh") { it.fileMode 0770 }
183184

184-
from("src/sdk_lib/src/api/include/appdynamics.h") { it.into "sdk_lib" }
185185
from(buildLibrary) { it.into "sdk_lib/lib" }
186-
from("${modDepDir}/opentelemetry/1.2.0/lib/libopentelemetry_common.so") { it.into "sdk_lib/lib" }
187-
from("${modDepDir}/opentelemetry/1.2.0/lib/libopentelemetry_resources.so") { it.into "sdk_lib/lib" }
188-
from("${modDepDir}/opentelemetry/1.2.0/lib/libopentelemetry_trace.so") { it.into "sdk_lib/lib" }
189-
from("${modDepDir}/opentelemetry/1.2.0/lib/libopentelemetry_otlp_recordable.so") { it.into "sdk_lib/lib" }
190-
from("${modDepDir}/opentelemetry/1.2.0/lib/libopentelemetry_exporter_ostream_span.so") { it.into "sdk_lib/lib" }
191-
from("${modDepDir}/opentelemetry/1.2.0/lib/libopentelemetry_exporter_otlp_grpc.so") { it.into "sdk_lib/lib" }
192-
from("dist/appdynamics_sdk_log4cxx.xml.template") { it.into "conf" }
186+
from("${modDepDir}/opentelemetry/${cppSDKVersion}/lib/libopentelemetry_common.so") { it.into "sdk_lib/lib" }
187+
from("${modDepDir}/opentelemetry/${cppSDKVersion}/lib/libopentelemetry_resources.so") { it.into "sdk_lib/lib" }
188+
from("${modDepDir}/opentelemetry/${cppSDKVersion}/lib/libopentelemetry_trace.so") { it.into "sdk_lib/lib" }
189+
from("${modDepDir}/opentelemetry/${cppSDKVersion}/lib/libopentelemetry_otlp_recordable.so") { it.into "sdk_lib/lib" }
190+
from("${modDepDir}/opentelemetry/${cppSDKVersion}/lib/libopentelemetry_exporter_ostream_span.so") { it.into "sdk_lib/lib" }
191+
from("${modDepDir}/opentelemetry/${cppSDKVersion}/lib/libopentelemetry_exporter_otlp_grpc.so") { it.into "sdk_lib/lib" }
192+
from("dist/opentelemetry_sdk_log4cxx.xml.template") { it.into "conf" }
193193
from("dist/install.${scriptExt}") { it.fileMode 0700 }
194194

195195
into libraryStageDir
@@ -295,7 +295,7 @@ task gypApacheModule(type: Exec) {
295295
ARCH_FLAG: gccArchFlag,
296296
APACHE22_INCLUDE_DIR: "${platBuildDir}/httpd-${apache22Version}/include",
297297
APACHE24_INCLUDE_DIR: "${platBuildDir}/httpd-${apache24Version}/include",
298-
APPD_SDK_LIB_DIR: "${libraryStageDir}/sdk_lib",
298+
OTEL_SDK_LIB_DIR: "${libraryStageDir}/sdk_lib",
299299
ANSDK_DIR: modDepDir,
300300
COMPILER_FLAGS: (coverageEnabled) ? coverageCompilerFlags : '',
301301
LINKER_FLAGS: (coverageEnabled) ? coverageLinkerFlags : '',
@@ -495,13 +495,14 @@ task gypUnitTest(type: Exec) {
495495
outputs.file "${platBuildDir}/unit_test/Makefile"
496496

497497
ext.testBuildEnvironment = [
498-
APPD_SDK_LIB_DIR: "${libraryStageDir}/sdk_lib",
498+
OTEL_SDK_LIB_DIR: "${libraryStageDir}/sdk_lib",
499499
ANSDK_DIR: modDepDir,
500500
BOOST_LIB: BOOST_LIB,
501501
BOOST_INCLUDE: BOOST_INCLUDE,
502502
GTEST_LIB_DIR: target_system == "ubuntu" ?
503503
"${modDepDir}/googletest/1.10.0/lib" : "${modDepDir}/googletest/1.10.0/lib64",
504504
LIBRARY_FLAGS: libraryFlags,
505+
CPP_SDK_VERSION: cppSDKVersion,
505506
]
506507

507508
environment testBuildEnvironment
@@ -634,9 +635,9 @@ model {
634635

635636
repositories {
636637
libs(PrebuiltLibraries) { libs ->
637-
appd {
638+
otel {
638639
headers.srcDirs "${libraryStageDir}/sdk_lib"
639-
// See FIXME on sources.cpp.lib library: 'appd' above
640+
// See FIXME on sources.cpp.lib library: 'otel' above
640641
// binaries.withType(SharedLibraryBinary) {
641642
// sharedLibraryFile = file("${libraryStageDir}/sdk_lib/lib/libopentelemetry_webserver_sdk.so")
642643
// }

instrumentation/otel-webserver-module/dist/Install_Native.txt

Lines changed: 0 additions & 27 deletions
This file was deleted.

instrumentation/otel-webserver-module/dist/install.sh

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ fi
5151

5252
log() {
5353
echo "$@" >> ${install_log}
54-
if [ -z "${APPD_AUTO_MODE}" ]; then
54+
if [ -z "${OTEL_AUTO_MODE}" ]; then
5555
echo "$@"
5656
fi
5757
}
@@ -96,23 +96,23 @@ checkPathIsAccessible() {
9696
eval $__resultVarName="$__result"
9797
}
9898

99-
if [ -z "${APPD_LOCATION}" ]; then
100-
APPD_LOCATION=$containingDir
101-
APPD_PACKAGE=0
99+
if [ -z "${OTEL_LOCATION}" ]; then
100+
OTEL_LOCATION=$containingDir
101+
OTEL_PACKAGE=0
102102
else
103-
APPD_PACKAGE=1
103+
OTEL_PACKAGE=1
104104
fi
105105

106106
datestamp=`date +%Y_%m_%d_%H_%M_%S 2>/dev/null`
107-
install_log=/tmp/appd_install_${datestamp}.log
107+
install_log=/tmp/otel_install_${datestamp}.log
108108
rm -f $install_log > /dev/null 2>&1
109109
cat > $install_log <<EOF
110110
Webserver Instrumentation installation log
111111
Version: ${agentVersionId}
112112
Date: `date 2>/dev/null`
113113
114114
Hostname: `hostname`
115-
Location: ${APPD_LOCATION}
115+
Location: ${OTEL_LOCATION}
116116
System: `uname -a 2>/dev/null`
117117
User: `id`
118118
Environment:
@@ -128,12 +128,12 @@ getenforce=`which getenforce 2>/dev/null`
128128
if [ -f "${getenforce}" ]; then
129129
selStatus=`$getenforce`
130130
if [ "$selStatus" = "Enforcing" ] ; then
131-
log "Warning: You may encounter issues with SELinux and AppDynamics. Please refer to the AppDynamics documentation at https://docs.appdynamics.com for information on creating an SELinux policy for AppDynamics support."
131+
log "Warning: You may encounter issues with SELinux and Opentelemetry. Please refer to https://github.com/open-telemetry/opentelemetry-cpp-contrib/tree/main/instrumentation/otel-webserver-module for more details"
132132
fi
133133
fi
134134

135135
## Installed files locations
136-
log4cxxFile="${containingDir}/conf/appdynamics_sdk_log4cxx.xml"
136+
log4cxxFile="${containingDir}/conf/opentelemetry_sdk_log4cxx.xml"
137137

138138
rootDirCheck=
139139
checkPathIsAccessible rootDirCheck "${containingDir}"

instrumentation/otel-webserver-module/dist/appdynamics_sdk_log4cxx.xml.template renamed to instrumentation/otel-webserver-module/dist/opentelemetry_sdk_log4cxx.xml.template

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<param name="MaxBackupIndex" value="5"/>
99
<layout class="org.apache.log4j.PatternLayout">
1010
<param name="ConversionPattern" value="%d{yyyy-MM-dd HH:mm:ss.SSS z} %-5p %X{pid}[%t] [%c{2}] %m%n" />
11-
<param name="HeaderPattern" value="AppDynamics Native SDK %X{version} %X{pid}%n" />
11+
<param name="HeaderPattern" value="Opentelemetry Webserver %X{version} %X{pid}%n" />
1212
</layout>
1313
</appender>
1414

@@ -19,7 +19,7 @@
1919
<param name="MaxBackupIndex" value="5"/>
2020
<layout class="org.apache.log4j.PatternLayout">
2121
<param name="ConversionPattern" value="%d{yyyy-MM-dd HH:mm:ss.SSS z} %-5p %X{pid} [%t] [%c{2}] %m%n" />
22-
<param name="HeaderPattern" value="AppDynamics Native SDK %X{version} %X{pid}%n" />
22+
<param name="HeaderPattern" value="Opentelemetry Webserver %X{version} %X{pid}%n" />
2323
</layout>
2424
</appender>
2525

@@ -30,7 +30,7 @@
3030
<param name="MaxBackupIndex" value="5"/>
3131
<layout class="org.apache.log4j.PatternLayout">
3232
<param name="ConversionPattern" value="%d{yyyy-MM-dd HH:mm:ss.SSS z} %-5p %X{pid} [%t] [%c{2}] %m%n" />
33-
<param name="HeaderPattern" value="AppDynamics Native SDK %X{version} %X{pid}%n" />
33+
<param name="HeaderPattern" value="Opentelemetry Webserver %X{version} %X{pid}%n" />
3434
</layout>
3535
</appender>
3636

instrumentation/otel-webserver-module/include/apache/ApacheHooks.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
#ifndef APACHEHOOKS_H
1919
#define APACHEHOOKS_H
2020

21-
#include <api/AppdynamicsSdk.h>
21+
#include <api/OpentelemetrySdk.h>
2222
#include <unordered_map>
2323
#include "HookContainer.h"
2424
#include "ExcludedModules.h"
@@ -116,7 +116,6 @@ class ApacheHooksForStage
116116
Hooks to occur before a module to start an interaction for a stage.
117117
These hooks are stage specific and each hook corresponds to a particular module.
118118
The number of hooks are proportional to the number of modules instrumented for a stage.
119-
See "AppDynamicsReportAllInstrumentedModules" flag for more details.
120119
TODO: Decide among the following stages at what all we need the modules to be instrumented,
121120
and define the hooks handlers for the same to start an interaction before module callback.
122121
*/

instrumentation/otel-webserver-module/include/core/api/ApiUtils.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
#include <string>
2121
#include <map>
22-
#include <api/AppdynamicsSdk.h>
22+
#include <api/OpentelemetrySdk.h>
2323
#include "AgentLogger.h"
2424
#include <api/Interface.h>
2525

instrumentation/otel-webserver-module/include/core/api/Interface.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#pragma once
1717

1818
#include <unordered_map>
19-
#include <api/AppdynamicsSdk.h>
19+
#include <api/OpentelemetrySdk.h>
2020
#include <api/TenantConfig.h>
2121
#include <api/SpanNamer.h>
2222

instrumentation/otel-webserver-module/include/core/api/AppdynamicsSdk.h renamed to instrumentation/otel-webserver-module/include/core/api/OpentelemetrySdk.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
* limitations under the License.
1515
*/
1616

17-
#ifndef APPDYNAMICS_SDK_H
18-
#define APPDYNAMICS_SDK_H
17+
#ifndef OPENTELEMETRY_SDK_H
18+
#define OPENTELEMETRY_SDK_H
1919

2020
#include <stddef.h>
2121

@@ -135,4 +135,4 @@ typedef struct _OTEL_SDK_ENV_RECORD
135135
} OTEL_SDK_ENV_RECORD;
136136
/* }}} */
137137

138-
#endif /* APPDYNAMICS_SDK_H */
138+
#endif /* OPENTELEMETRY_SDK_H */

instrumentation/otel-webserver-module/include/core/api/RequestProcessingEngine.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#ifndef REQUEST_PROCESSOR_ENGINE_H
1818
#define REQUEST_PROCESSOR_ENGINE_H
1919

20-
#include "api/AppdynamicsSdk.h"
20+
#include "api/OpentelemetrySdk.h"
2121
#include "api/SpanNamer.h"
2222
#include "RequestContext.h"
2323
#include "AgentLogger.h"

instrumentation/otel-webserver-module/include/core/api/WSAgent.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#ifndef OTEL_WS_AGENT_H
1818
#define OTEL_WS_AGENT_H
1919

20-
#include "api/AppdynamicsSdk.h"
20+
#include "api/OpentelemetrySdk.h"
2121
#include <string>
2222
#include <memory>
2323
#include <unordered_map>

0 commit comments

Comments
 (0)