[ https://issues.apache.org/jira/browse/TS-204?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12838511#action_12838511 ]
Bryan Call commented on TS-204: ------------------------------- After checking to see if this was a problem with librecords and not syncing the snapshot file properly between traffic server and traffic manager, this was not the problem, it ended up being a bug with ink_sprintf(). We pass a 0 length size of the buffer to ink_snprintf() and that calls vsnprintf() with a zero buffer size. This ends up leaving the string as '\0' and cause us to print "NULL" as the returning stat value from traffic_line. I am going to change the implementation of ink_sprintf() to call vsprintf(). Right now everywhere we use ink_sprintf() we will get a NULL string. Number of places we use ink_sprintf: [bc...@snowball trafficserver]$ grep -r ink_sprintf * | grep -v Binary | grep -v .deps | grep -v Makefile | grep -v libinktomi++/ink_sprintf | grep -v libinktomi++/ink_snprintf | wc -l 41 This bug was introduce when fixing Coverity issues before open sourcing. We switched ink_snprintf to not use an internal implementation. > not able to get stats from traffic_line > --------------------------------------- > > Key: TS-204 > URL: https://issues.apache.org/jira/browse/TS-204 > Project: Traffic Server > Issue Type: Bug > Environment: Fedora 12 x86_64 > Reporter: Bryan Call > Assignee: Bryan Call > Fix For: 2.0.0a > > > Stats are showing up as NULL values from traffic_line: > /usr/local/bin/traffic_line -r > proxy.node.http.user_agent_current_connections_count > NULL -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.