Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/docker-images/integration-tests/ubuntu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ RUN wget https://zlib.net/zlib-1.3.1.tar.gz -O /tmp/zlib-1.3.1.tar.gz && \
make install && \
cd /home/dependencies

RUN wget https://boostorg.jfrog.io/artifactory/main/release/1.81.0/source/boost_1_81_0.tar.gz -O /tmp/boost.tar.gz && \
RUN wget https://archives.boost.io/release/1.87.0/source/boost_1_87_0.tar.gz -O /tmp/boost.tar.gz && \
tar xzvf /tmp/boost.tar.gz && \
cd boost_1_81_0 && \
cd boost_1_87_0 && \
./bootstrap.sh && \
./b2 install link=static && \
cd /home/dependencies
Expand Down
20 changes: 13 additions & 7 deletions integration-tests/source/IntegrationTestResourceHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,12 @@ extern std::string THING_NAME;
static const char *TAG = "IntegrationTestResourceHandler.cpp";

IntegrationTestResourceHandler::IntegrationTestResourceHandler(const ClientConfiguration &clientConfig)
: iotClient(IoTClient(clientConfig)), ioTSecureTunnelingClient(IoTSecureTunnelingClient(clientConfig))
: iotClient(IoTClient(clientConfig)),
ioTSecureTunnelingClient(IoTSecureTunnelingClient(clientConfig)),
logger(std::unique_ptr<Aws::Utils::Logging::ConsoleLogSystem>(
new Aws::Utils::Logging::ConsoleLogSystem(Aws::Utils::Logging::LogLevel::Info)))
{
targetArn = GetTargetArn(THING_NAME);
logger = unique_ptr<Aws::Utils::Logging::ConsoleLogSystem>(
new Aws::Utils::Logging::ConsoleLogSystem(Aws::Utils::Logging::LogLevel::Info));
}

void IntegrationTestResourceHandler::CreateJob(const string &jobId, const string &jobDoc)
Expand All @@ -66,7 +67,6 @@ void IntegrationTestResourceHandler::CreateJob(const string &jobId, const string
request.SetJobId(jobId);
request.SetDocument(jobDoc);
request.AddTargets(targetArn);

CreateJobOutcome outcome = iotClient.CreateJob(request);

if (outcome.IsSuccess())
Expand Down Expand Up @@ -504,6 +504,12 @@ void IntegrationTestResourceHandler::Log(
{
ss << string{" "} << errorMessage;
}

logger->LogStream(logLevel, TAG, ss);
}
if (logger)
{
logger->LogStream(logLevel, TAG, ss);
}
else
{
std::cerr << "[ERROR] Logger not initialized. Message: " << ss.str() << std::endl;
}
}
Loading