{"action":"created","comment":{"url":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/comments/220773303","pull_request_review_id":159259214,"id":220773303,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyMDc3MzMwMw==","diff_hunk":"@@ -174,11 +182,22 @@ def reinit_data(self):\n         if not self.loc_port_data:\n             logger.warning(\"0 - b'PORT_TABLE' is empty. No local port information could be retrieved.\")\n \n+    def _get_if_entry(self, if_name):\n+        if_table = \"\"\n+\n+        if if_name in self.if_name_map:\n+            if_table = mibs.if_entry_table(if_name)\n+        elif if_name in self.mgmt_oid_name_map.values():\n+            if_table = mibs.mgmt_if_entry_table(if_name)","path":"src/sonic_ax_impl/mibs/ieee802_1ab.py","position":45,"original_position":45,"commit_id":"02c6c11efa50b8b7e9c2bc3921c897886a548ef4","original_commit_id":"02c6c11efa50b8b7e9c2bc3921c897886a548ef4","user":{"login":"qiluo-msft","id":11406616,"node_id":"MDQ6VXNlcjExNDA2NjE2","avatar_url":"https://avatars1.githubusercontent.com/u/11406616?v=4","gravatar_id":"","url":"https://api.github.com/users/qiluo-msft","html_url":"https://github.com/qiluo-msft","followers_url":"https://api.github.com/users/qiluo-msft/followers","following_url":"https://api.github.com/users/qiluo-msft/following{/other_user}","gists_url":"https://api.github.com/users/qiluo-msft/gists{/gist_id}","starred_url":"https://api.github.com/users/qiluo-msft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/qiluo-msft/subscriptions","organizations_url":"https://api.github.com/users/qiluo-msft/orgs","repos_url":"https://api.github.com/users/qiluo-msft/repos","events_url":"https://api.github.com/users/qiluo-msft/events{/privacy}","received_events_url":"https://api.github.com/users/qiluo-msft/received_events","type":"User","site_admin":false},"body":">f_table = mibs.mgmt_if_entry_table(if_name) [](start = 13, length = 43)\r\n\r\nadd 'else' at the end?","created_at":"2018-09-27T01:50:28Z","updated_at":"2018-09-27T01:50:28Z","html_url":"https://github.com/Azure/sonic-snmpagent/pull/88#discussion_r220773303","pull_request_url":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/88","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/comments/220773303"},"html":{"href":"https://github.com/Azure/sonic-snmpagent/pull/88#discussion_r220773303"},"pull_request":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/88"}}},"pull_request":{"url":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/88","id":218233013,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE4MjMzMDEz","html_url":"https://github.com/Azure/sonic-snmpagent/pull/88","diff_url":"https://github.com/Azure/sonic-snmpagent/pull/88.diff","patch_url":"https://github.com/Azure/sonic-snmpagent/pull/88.patch","issue_url":"https://api.github.com/repos/Azure/sonic-snmpagent/issues/88","number":88,"state":"open","locked":false,"title":"Add managment port support to RFC1213, RFC2863, IEEE802.1ab MIBs","user":{"login":"stepanblyschak","id":38952541,"node_id":"MDQ6VXNlcjM4OTUyNTQx","avatar_url":"https://avatars0.githubusercontent.com/u/38952541?v=4","gravatar_id":"","url":"https://api.github.com/users/stepanblyschak","html_url":"https://github.com/stepanblyschak","followers_url":"https://api.github.com/users/stepanblyschak/followers","following_url":"https://api.github.com/users/stepanblyschak/following{/other_user}","gists_url":"https://api.github.com/users/stepanblyschak/gists{/gist_id}","starred_url":"https://api.github.com/users/stepanblyschak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stepanblyschak/subscriptions","organizations_url":"https://api.github.com/users/stepanblyschak/orgs","repos_url":"https://api.github.com/users/stepanblyschak/repos","events_url":"https://api.github.com/users/stepanblyschak/events{/privacy}","received_events_url":"https://api.github.com/users/stepanblyschak/received_events","type":"User","site_admin":false},"body":"Signed-off-by: Stepan Blyschak <stepanb@mellanox.com>\r\n\r\n<!--\r\nPlease make sure you've read and understood our contributing guidelines;\r\nhttps://github.com/Azure/SONiC/blob/gh-pages/CONTRIBUTING.md\r\n\r\n** Make sure all your commits include a signature generated with `git commit -s` **\r\n\r\nIf this is a bug fix, make sure your description includes \"fixes #xxxx\", or\r\n\"closes #xxxx\"\r\n\r\nPlease provide the following information:\r\n-->\r\n\r\n**- What I did**\r\nAdd management port support to Interface/LLDP MIBs\r\n\r\n**- How I did it**\r\nImplement this by getting management port info from MGMT_PORT_TABLE from APPL DB\r\n\r\n**- How to verify it**\r\nInsert some fake entries into MGMT_PORT_TABLE and make verify they are present in above MIBs\r\n\r\n**- Description for the changelog**\r\nAdd managment port support to RFC1213, RFC2863, IEEE802.1ab MIBs\r\n<!--\r\nWrite a short (one line) summary that describes the changes in this\r\npull request for inclusion in the changelog:\r\n-->\r\n\r\n\r\n","created_at":"2018-09-26T08:43:53Z","updated_at":"2018-09-27T01:50:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a99325fdc06d84d2a4956af50bc90042c2daa29c","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/88/commits","review_comments_url":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/88/comments","review_comment_url":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Azure/sonic-snmpagent/issues/88/comments","statuses_url":"https://api.github.com/repos/Azure/sonic-snmpagent/statuses/02c6c11efa50b8b7e9c2bc3921c897886a548ef4","head":{"label":"stepanblyschak:mgmt_ports","ref":"mgmt_ports","sha":"02c6c11efa50b8b7e9c2bc3921c897886a548ef4","user":{"login":"stepanblyschak","id":38952541,"node_id":"MDQ6VXNlcjM4OTUyNTQx","avatar_url":"https://avatars0.githubusercontent.com/u/38952541?v=4","gravatar_id":"","url":"https://api.github.com/users/stepanblyschak","html_url":"https://github.com/stepanblyschak","followers_url":"https://api.github.com/users/stepanblyschak/followers","following_url":"https://api.github.com/users/stepanblyschak/following{/other_user}","gists_url":"https://api.github.com/users/stepanblyschak/gists{/gist_id}","starred_url":"https://api.github.com/users/stepanblyschak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stepanblyschak/subscriptions","organizations_url":"https://api.github.com/users/stepanblyschak/orgs","repos_url":"https://api.github.com/users/stepanblyschak/repos","events_url":"https://api.github.com/users/stepanblyschak/events{/privacy}","received_events_url":"https://api.github.com/users/stepanblyschak/received_events","type":"User","site_admin":false},"repo":{"id":138410829,"node_id":"MDEwOlJlcG9zaXRvcnkxMzg0MTA4Mjk=","name":"sonic-snmpagent","full_name":"stepanblyschak/sonic-snmpagent","private":false,"owner":{"login":"stepanblyschak","id":38952541,"node_id":"MDQ6VXNlcjM4OTUyNTQx","avatar_url":"https://avatars0.githubusercontent.com/u/38952541?v=4","gravatar_id":"","url":"https://api.github.com/users/stepanblyschak","html_url":"https://github.com/stepanblyschak","followers_url":"https://api.github.com/users/stepanblyschak/followers","following_url":"https://api.github.com/users/stepanblyschak/following{/other_user}","gists_url":"https://api.github.com/users/stepanblyschak/gists{/gist_id}","starred_url":"https://api.github.com/users/stepanblyschak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stepanblyschak/subscriptions","organizations_url":"https://api.github.com/users/stepanblyschak/orgs","repos_url":"https://api.github.com/users/stepanblyschak/repos","events_url":"https://api.github.com/users/stepanblyschak/events{/privacy}","received_events_url":"https://api.github.com/users/stepanblyschak/received_events","type":"User","site_admin":false},"html_url":"https://github.com/stepanblyschak/sonic-snmpagent","description":"A net-snmpd agentx subagent for SONiC","fork":true,"url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent","forks_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/forks","keys_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/teams","hooks_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/hooks","issue_events_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/issues/events{/number}","events_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/events","assignees_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/assignees{/user}","branches_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/branches{/branch}","tags_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/tags","blobs_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/git/refs{/sha}","trees_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/statuses/{sha}","languages_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/languages","stargazers_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/stargazers","contributors_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/contributors","subscribers_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/subscribers","subscription_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/subscription","commits_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/commits{/sha}","git_commits_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/git/commits{/sha}","comments_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/comments{/number}","issue_comment_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/issues/comments{/number}","contents_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/contents/{+path}","compare_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/merges","archive_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/downloads","issues_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/issues{/number}","pulls_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/pulls{/number}","milestones_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/milestones{/number}","notifications_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/labels{/name}","releases_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/releases{/id}","deployments_url":"https://api.github.com/repos/stepanblyschak/sonic-snmpagent/deployments","created_at":"2018-06-23T15:09:25Z","updated_at":"2018-06-23T15:09:27Z","pushed_at":"2018-09-26T08:37:55Z","git_url":"git://github.com/stepanblyschak/sonic-snmpagent.git","ssh_url":"git@github.com:stepanblyschak/sonic-snmpagent.git","clone_url":"https://github.com/stepanblyschak/sonic-snmpagent.git","svn_url":"https://github.com/stepanblyschak/sonic-snmpagent","homepage":null,"size":214,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"Azure:master","ref":"master","sha":"7383cd53d9c0c68d394fe92a03cb9a68f75e3c6b","user":{"login":"Azure","id":6844498,"node_id":"MDEyOk9yZ2FuaXphdGlvbjY4NDQ0OTg=","avatar_url":"https://avatars0.githubusercontent.com/u/6844498?v=4","gravatar_id":"","url":"https://api.github.com/users/Azure","html_url":"https://github.com/Azure","followers_url":"https://api.github.com/users/Azure/followers","following_url":"https://api.github.com/users/Azure/following{/other_user}","gists_url":"https://api.github.com/users/Azure/gists{/gist_id}","starred_url":"https://api.github.com/users/Azure/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Azure/subscriptions","organizations_url":"https://api.github.com/users/Azure/orgs","repos_url":"https://api.github.com/users/Azure/repos","events_url":"https://api.github.com/users/Azure/events{/privacy}","received_events_url":"https://api.github.com/users/Azure/received_events","type":"Organization","site_admin":false},"repo":{"id":53432617,"node_id":"MDEwOlJlcG9zaXRvcnk1MzQzMjYxNw==","name":"sonic-snmpagent","full_name":"Azure/sonic-snmpagent","private":false,"owner":{"login":"Azure","id":6844498,"node_id":"MDEyOk9yZ2FuaXphdGlvbjY4NDQ0OTg=","avatar_url":"https://avatars0.githubusercontent.com/u/6844498?v=4","gravatar_id":"","url":"https://api.github.com/users/Azure","html_url":"https://github.com/Azure","followers_url":"https://api.github.com/users/Azure/followers","following_url":"https://api.github.com/users/Azure/following{/other_user}","gists_url":"https://api.github.com/users/Azure/gists{/gist_id}","starred_url":"https://api.github.com/users/Azure/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Azure/subscriptions","organizations_url":"https://api.github.com/users/Azure/orgs","repos_url":"https://api.github.com/users/Azure/repos","events_url":"https://api.github.com/users/Azure/events{/privacy}","received_events_url":"https://api.github.com/users/Azure/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/Azure/sonic-snmpagent","description":"A net-snmpd agentx subagent for SONiC","fork":false,"url":"https://api.github.com/repos/Azure/sonic-snmpagent","forks_url":"https://api.github.com/repos/Azure/sonic-snmpagent/forks","keys_url":"https://api.github.com/repos/Azure/sonic-snmpagent/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Azure/sonic-snmpagent/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Azure/sonic-snmpagent/teams","hooks_url":"https://api.github.com/repos/Azure/sonic-snmpagent/hooks","issue_events_url":"https://api.github.com/repos/Azure/sonic-snmpagent/issues/events{/number}","events_url":"https://api.github.com/repos/Azure/sonic-snmpagent/events","assignees_url":"https://api.github.com/repos/Azure/sonic-snmpagent/assignees{/user}","branches_url":"https://api.github.com/repos/Azure/sonic-snmpagent/branches{/branch}","tags_url":"https://api.github.com/repos/Azure/sonic-snmpagent/tags","blobs_url":"https://api.github.com/repos/Azure/sonic-snmpagent/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Azure/sonic-snmpagent/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Azure/sonic-snmpagent/git/refs{/sha}","trees_url":"https://api.github.com/repos/Azure/sonic-snmpagent/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Azure/sonic-snmpagent/statuses/{sha}","languages_url":"https://api.github.com/repos/Azure/sonic-snmpagent/languages","stargazers_url":"https://api.github.com/repos/Azure/sonic-snmpagent/stargazers","contributors_url":"https://api.github.com/repos/Azure/sonic-snmpagent/contributors","subscribers_url":"https://api.github.com/repos/Azure/sonic-snmpagent/subscribers","subscription_url":"https://api.github.com/repos/Azure/sonic-snmpagent/subscription","commits_url":"https://api.github.com/repos/Azure/sonic-snmpagent/commits{/sha}","git_commits_url":"https://api.github.com/repos/Azure/sonic-snmpagent/git/commits{/sha}","comments_url":"https://api.github.com/repos/Azure/sonic-snmpagent/comments{/number}","issue_comment_url":"https://api.github.com/repos/Azure/sonic-snmpagent/issues/comments{/number}","contents_url":"https://api.github.com/repos/Azure/sonic-snmpagent/contents/{+path}","compare_url":"https://api.github.com/repos/Azure/sonic-snmpagent/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Azure/sonic-snmpagent/merges","archive_url":"https://api.github.com/repos/Azure/sonic-snmpagent/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Azure/sonic-snmpagent/downloads","issues_url":"https://api.github.com/repos/Azure/sonic-snmpagent/issues{/number}","pulls_url":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls{/number}","milestones_url":"https://api.github.com/repos/Azure/sonic-snmpagent/milestones{/number}","notifications_url":"https://api.github.com/repos/Azure/sonic-snmpagent/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Azure/sonic-snmpagent/labels{/name}","releases_url":"https://api.github.com/repos/Azure/sonic-snmpagent/releases{/id}","deployments_url":"https://api.github.com/repos/Azure/sonic-snmpagent/deployments","created_at":"2016-03-08T17:44:49Z","updated_at":"2018-09-26T01:32:08Z","pushed_at":"2018-09-26T08:43:53Z","git_url":"git://github.com/Azure/sonic-snmpagent.git","ssh_url":"git@github.com:Azure/sonic-snmpagent.git","clone_url":"https://github.com/Azure/sonic-snmpagent.git","svn_url":"https://github.com/Azure/sonic-snmpagent","homepage":null,"size":206,"stargazers_count":5,"watchers_count":5,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":22,"mirror_url":null,"archived":false,"open_issues_count":17,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":22,"open_issues":17,"watchers":5,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/88"},"html":{"href":"https://github.com/Azure/sonic-snmpagent/pull/88"},"issue":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/issues/88"},"comments":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/issues/88/comments"},"review_comments":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/88/comments"},"review_comment":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/pulls/88/commits"},"statuses":{"href":"https://api.github.com/repos/Azure/sonic-snmpagent/statuses/02c6c11efa50b8b7e9c2bc3921c897886a548ef4"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"qiluo-msft"}}