[cpp-sp] branch master updated: Hide deprecated log member.
Scott Cantor
cantor.2 at osu.edu
Mon Feb 5 15:27:55 EST 2018
This is an automated email from the git hooks/post-receive script.
scantor pushed a commit to branch master
in repository cpp-sp.
View the commit online:
http://git.shibboleth.net/view/?p=cpp-sp.git;a=commit;h=abbcc75225dd936bedbd98ec126d522f9082f41e
The following commit(s) were added to refs/heads/master by this push:
new abbcc75 Hide deprecated log member.
abbcc75 is described below
commit abbcc75225dd936bedbd98ec126d522f9082f41e
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Mon Feb 5 15:27:52 2018 -0500
Hide deprecated log member.
---
shibsp/TransactionLog.h | 7 +------
shibsp/impl/TransactionLog.cpp | 12 ++++++------
2 files changed, 7 insertions(+), 12 deletions(-)
diff --git a/shibsp/TransactionLog.h b/shibsp/TransactionLog.h
index c4a8fbc..5efb4e4 100644
--- a/shibsp/TransactionLog.h
+++ b/shibsp/TransactionLog.h
@@ -76,9 +76,6 @@ namespace shibsp {
/**
* Interface to a synchronized event/audit logging object.
- *
- * <p>For backward compatibility, we expose a logging object directly, but
- * new applications should rely on the Event callback API.
*/
class SHIBSP_API TransactionLog : public virtual xmltooling::Lockable
{
@@ -97,9 +94,6 @@ namespace shibsp {
xmltooling::Lockable* lock();
void unlock();
- /** @deprecated Logging object. */
- xmltooling::logging::Category& log;
-
/**
* Callback interface that outputs an event record to a stream using formatting tokens.
*/
@@ -172,6 +166,7 @@ namespace shibsp {
virtual void write(const Event& e);
private:
+ xmltooling::logging::Category& m_log;
boost::scoped_ptr<xmltooling::Mutex> m_lock;
std::string m_absent;
std::vector<std::string> m_formatting;
diff --git a/shibsp/impl/TransactionLog.cpp b/shibsp/impl/TransactionLog.cpp
index 211baed..964b0a1 100644
--- a/shibsp/impl/TransactionLog.cpp
+++ b/shibsp/impl/TransactionLog.cpp
@@ -82,7 +82,7 @@ void SHIBSP_API shibsp::registerEvents()
}
TransactionLog::TransactionLog(const char* fmt, const char* absent)
- : log(logging::Category::getInstance(SHIBSP_TX_LOGCAT)), m_lock(Mutex::create()), m_absent(absent ? absent : "")
+ : m_log(logging::Category::getInstance(SHIBSP_TX_LOGCAT)), m_lock(Mutex::create()), m_absent(absent ? absent : "")
{
// Split the formatting string into named '%' parameter tokens, and "other stuff" to be echoed
// literally in log messages.
@@ -154,7 +154,7 @@ void TransactionLog::write(const TransactionLog::Event& e)
os << ")";
Locker locker(this);
- log.info(os.str());
+ m_log.info(os.str());
os.str("");
os << "Cached the following attributes with session (ID: ";
@@ -162,14 +162,14 @@ void TransactionLog::write(const TransactionLog::Event& e)
os << ") for (applicationId: ";
login->write(os, "%app", nullptr);
os << ") {";
- log.info(os.str());
+ m_log.info(os.str());
if (login->m_attributes) {
for (vector<Attribute*>::const_iterator a=login->m_attributes->begin(); a != login->m_attributes->end(); ++a)
- log.infoStream() << "\t" << (*a)->getId() << " (" << (*a)->valueCount() << " values)";
+ m_log.infoStream() << "\t" << (*a)->getId() << " (" << (*a)->valueCount() << " values)";
}
- log.info("}");
+ m_log.info("}");
return;
}
@@ -180,7 +180,7 @@ void TransactionLog::write(const TransactionLog::Event& e)
os << ") (ID: ";
logout->write(os, "%s", nullptr);
os << ")";
- log.info(os.str());
+ m_log.info(os.str());
return;
}
}
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list