Bug 1355721

Summary: The value of skipcommit cannot be shown correctly when set router loglevel=4
Product: OpenShift Container Platform Reporter: Meng Bo <bmeng>
Component: NetworkingAssignee: Ram Ranganathan <ramr>
Networking sub component: router QA Contact: Meng Bo <bmeng>
Status: CLOSED ERRATA Docs Contact:
Severity: low    
Priority: medium CC: aos-bugs, bbennett, tdawson
Version: 3.2.1   
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
Verbose log message fix.
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-09-27 09:39:44 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Meng Bo 2016-07-12 10:47:34 UTC
Description of problem:
Set the router log level to 4 and check the log.
The skipcommit value cannot be shown as expected in the log.

# oc logs  router-3-w0kyn  | grep skip\ commit
I0712 09:35:13.603024       1 router.go:630] Updating skip commit to: %!s(bool=true)
I0712 09:37:15.227676       1 router.go:630] Updating skip commit to: %!s(bool=false)
I0712 09:45:14.592676       1 router.go:630] Updating skip commit to: %!s(bool=true)
I0712 09:45:14.780738       1 router.go:630] Updating skip commit to: %!s(bool=false)



Version-Release number of selected component (if applicable):
openshift 3.2.1.5

How reproducible:
always

Steps to Reproduce:
1. Create router on the env
2. Change the loglevel to 4 by editing the dc
3. Check the router pod log

Actual results:
# oc logs  router-3-w0kyn  | grep skip\ commit
I0712 09:35:13.603024       1 router.go:630] Updating skip commit to: %!s(bool=true)
I0712 09:37:15.227676       1 router.go:630] Updating skip commit to: %!s(bool=false)
I0712 09:45:14.592676       1 router.go:630] Updating skip commit to: %!s(bool=true)
I0712 09:45:14.780738       1 router.go:630] Updating skip commit to: %!s(bool=false)


Expected results:
Should show the value correctly.

Additional info:
[root@master ~]# grep -in "skipcommit" src/github.com/origin/pkg/router/template/router.go 
83:     skipCommit bool
255:    if r.skipCommit {
653:// SetSkipCommit indicates to the router whether requests to
655:func (r *templateRouter) SetSkipCommit(skipCommit bool) {
656:    if r.skipCommit != skipCommit {
657:            glog.V(4).Infof("Updating skip commit to: %s", skipCommit)
658:            r.skipCommit = skipCommit

Comment 1 Ram Ranganathan 2016-08-02 21:06:46 UTC
Associated PR: https://github.com/openshift/origin/pull/9872 

@bmeng  thx

Comment 2 Troy Dawson 2016-09-01 15:14:31 UTC
This has been merged into ose and is in OSE v3.3.0.28 or newer.

Comment 4 Meng Bo 2016-09-02 05:54:33 UTC
Checked on router image openshift3/ose-haproxy-router:v3.3.0.28 6ff97e2fd698

Issue has been fixed.

I0902 01:52:49.351771       1 router.go:330] Reloading the router
I0902 01:52:49.368650       1 router.go:710] Updating skip commit to: true

Comment 6 errata-xmlrpc 2016-09-27 09:39:44 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2016:1933