public void AddSqlInformation()

in sdk/src/Core/AWSXRayRecorderImpl.cs [572:598]


        public void AddSqlInformation(string key, string value)
        {
            if (IsTracingDisabled())
            {
                _logger.DebugFormat("X-Ray tracing is disabled, do not add sql information.");
                return;
            }

            if (string.IsNullOrEmpty(key))
            {
                throw new ArgumentException("Key cannot be null or empty", nameof(key));
            }

            if (string.IsNullOrEmpty(value))
            {
                throw new ArgumentException("Value cannot be null or empty", nameof(value));
            }

            try
            {
                TraceContext.GetEntity().Sql[key] = value;
            }
            catch (EntityNotAvailableException e)
            {
                HandleEntityNotAvailableException(e, "Failed to add sql information because segment is not available in trace context.");
            }
        }