{"action":"created","comment":{"url":"https://api.github.com/repos/Catel/Catel/pulls/comments/72884262","id":72884262,"diff_hunk":"@@ -478,14 +558,30 @@ private void RemoveInterestedViewModelInstanceInternal(Type viewModelType, IView\n         /// <returns>The <see cref=\"ManagedViewModel\"/> of the specified type.</returns>\n         private ManagedViewModel GetManagedViewModel(Type viewModelType)\n         {\n-            lock (_managedViewModelsLock)\n+            _managedViewModelsLock.EnterUpgradeableReadLock();\n+            try\n             {\n-                if (!_managedViewModels.ContainsKey(viewModelType))\n+                ManagedViewModel result;\n+                if (_managedViewModels.TryGetValue(viewModelType, out result))\n+                {\n+                    return result;\n+                }\n+                _managedViewModelsLock.EnterWriteLock();\n+                try\n+                {\n+                    result = new ManagedViewModel(viewModelType);","path":"src/Catel.MVVM/Catel.MVVM.Shared/MVVM/ViewModels/ViewModelManager.cs","position":254,"original_position":254,"commit_id":"ac043425012713775c830693d41103912dab1921","original_commit_id":"ac043425012713775c830693d41103912dab1921","user":{"login":"szogun1987","id":7465665,"avatar_url":"https://avatars.githubusercontent.com/u/7465665?v=3","gravatar_id":"","url":"https://api.github.com/users/szogun1987","html_url":"https://github.com/szogun1987","followers_url":"https://api.github.com/users/szogun1987/followers","following_url":"https://api.github.com/users/szogun1987/following{/other_user}","gists_url":"https://api.github.com/users/szogun1987/gists{/gist_id}","starred_url":"https://api.github.com/users/szogun1987/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/szogun1987/subscriptions","organizations_url":"https://api.github.com/users/szogun1987/orgs","repos_url":"https://api.github.com/users/szogun1987/repos","events_url":"https://api.github.com/users/szogun1987/events{/privacy}","received_events_url":"https://api.github.com/users/szogun1987/received_events","type":"User","site_admin":false},"body":"this line should be placed out of lock block. will be fixed soon","created_at":"2016-07-30T08:45:32Z","updated_at":"2016-07-30T08:45:32Z","html_url":"https://github.com/Catel/Catel/pull/101#discussion_r72884262","pull_request_url":"https://api.github.com/repos/Catel/Catel/pulls/101","_links":{"self":{"href":"https://api.github.com/repos/Catel/Catel/pulls/comments/72884262"},"html":{"href":"https://github.com/Catel/Catel/pull/101#discussion_r72884262"},"pull_request":{"href":"https://api.github.com/repos/Catel/Catel/pulls/101"}}},"pull_request":{"url":"https://api.github.com/repos/Catel/Catel/pulls/101","id":79452221,"html_url":"https://github.com/Catel/Catel/pull/101","diff_url":"https://github.com/Catel/Catel/pull/101.diff","patch_url":"https://github.com/Catel/Catel/pull/101.patch","issue_url":"https://api.github.com/repos/Catel/Catel/issues/101","number":101,"state":"open","locked":false,"title":"CTL-904 Problems with creating ViewModels on multiple threads","user":{"login":"szogun1987","id":7465665,"avatar_url":"https://avatars.githubusercontent.com/u/7465665?v=3","gravatar_id":"","url":"https://api.github.com/users/szogun1987","html_url":"https://github.com/szogun1987","followers_url":"https://api.github.com/users/szogun1987/followers","following_url":"https://api.github.com/users/szogun1987/following{/other_user}","gists_url":"https://api.github.com/users/szogun1987/gists{/gist_id}","starred_url":"https://api.github.com/users/szogun1987/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/szogun1987/subscriptions","organizations_url":"https://api.github.com/users/szogun1987/orgs","repos_url":"https://api.github.com/users/szogun1987/repos","events_url":"https://api.github.com/users/szogun1987/events{/privacy}","received_events_url":"https://api.github.com/users/szogun1987/received_events","type":"User","site_admin":false},"body":"Mine proposition of fixing one of thread related issues in Catel.","created_at":"2016-07-30T08:42:11Z","updated_at":"2016-07-30T08:45:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"bd17c910be294b2d97d30f03c2566ef704357917","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/Catel/Catel/pulls/101/commits","review_comments_url":"https://api.github.com/repos/Catel/Catel/pulls/101/comments","review_comment_url":"https://api.github.com/repos/Catel/Catel/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Catel/Catel/issues/101/comments","statuses_url":"https://api.github.com/repos/Catel/Catel/statuses/ac043425012713775c830693d41103912dab1921","head":{"label":"szogun1987:bugfix/CTL-904_Problems_with_creating_ViewModels_on_multiple_threads","ref":"bugfix/CTL-904_Problems_with_creating_ViewModels_on_multiple_threads","sha":"ac043425012713775c830693d41103912dab1921","user":{"login":"szogun1987","id":7465665,"avatar_url":"https://avatars.githubusercontent.com/u/7465665?v=3","gravatar_id":"","url":"https://api.github.com/users/szogun1987","html_url":"https://github.com/szogun1987","followers_url":"https://api.github.com/users/szogun1987/followers","following_url":"https://api.github.com/users/szogun1987/following{/other_user}","gists_url":"https://api.github.com/users/szogun1987/gists{/gist_id}","starred_url":"https://api.github.com/users/szogun1987/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/szogun1987/subscriptions","organizations_url":"https://api.github.com/users/szogun1987/orgs","repos_url":"https://api.github.com/users/szogun1987/repos","events_url":"https://api.github.com/users/szogun1987/events{/privacy}","received_events_url":"https://api.github.com/users/szogun1987/received_events","type":"User","site_admin":false},"repo":{"id":61831287,"name":"Catel","full_name":"szogun1987/Catel","owner":{"login":"szogun1987","id":7465665,"avatar_url":"https://avatars.githubusercontent.com/u/7465665?v=3","gravatar_id":"","url":"https://api.github.com/users/szogun1987","html_url":"https://github.com/szogun1987","followers_url":"https://api.github.com/users/szogun1987/followers","following_url":"https://api.github.com/users/szogun1987/following{/other_user}","gists_url":"https://api.github.com/users/szogun1987/gists{/gist_id}","starred_url":"https://api.github.com/users/szogun1987/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/szogun1987/subscriptions","organizations_url":"https://api.github.com/users/szogun1987/orgs","repos_url":"https://api.github.com/users/szogun1987/repos","events_url":"https://api.github.com/users/szogun1987/events{/privacy}","received_events_url":"https://api.github.com/users/szogun1987/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/szogun1987/Catel","description":"An application development platform","fork":true,"url":"https://api.github.com/repos/szogun1987/Catel","forks_url":"https://api.github.com/repos/szogun1987/Catel/forks","keys_url":"https://api.github.com/repos/szogun1987/Catel/keys{/key_id}","collaborators_url":"https://api.github.com/repos/szogun1987/Catel/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/szogun1987/Catel/teams","hooks_url":"https://api.github.com/repos/szogun1987/Catel/hooks","issue_events_url":"https://api.github.com/repos/szogun1987/Catel/issues/events{/number}","events_url":"https://api.github.com/repos/szogun1987/Catel/events","assignees_url":"https://api.github.com/repos/szogun1987/Catel/assignees{/user}","branches_url":"https://api.github.com/repos/szogun1987/Catel/branches{/branch}","tags_url":"https://api.github.com/repos/szogun1987/Catel/tags","blobs_url":"https://api.github.com/repos/szogun1987/Catel/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/szogun1987/Catel/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/szogun1987/Catel/git/refs{/sha}","trees_url":"https://api.github.com/repos/szogun1987/Catel/git/trees{/sha}","statuses_url":"https://api.github.com/repos/szogun1987/Catel/statuses/{sha}","languages_url":"https://api.github.com/repos/szogun1987/Catel/languages","stargazers_url":"https://api.github.com/repos/szogun1987/Catel/stargazers","contributors_url":"https://api.github.com/repos/szogun1987/Catel/contributors","subscribers_url":"https://api.github.com/repos/szogun1987/Catel/subscribers","subscription_url":"https://api.github.com/repos/szogun1987/Catel/subscription","commits_url":"https://api.github.com/repos/szogun1987/Catel/commits{/sha}","git_commits_url":"https://api.github.com/repos/szogun1987/Catel/git/commits{/sha}","comments_url":"https://api.github.com/repos/szogun1987/Catel/comments{/number}","issue_comment_url":"https://api.github.com/repos/szogun1987/Catel/issues/comments{/number}","contents_url":"https://api.github.com/repos/szogun1987/Catel/contents/{+path}","compare_url":"https://api.github.com/repos/szogun1987/Catel/compare/{base}...{head}","merges_url":"https://api.github.com/repos/szogun1987/Catel/merges","archive_url":"https://api.github.com/repos/szogun1987/Catel/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/szogun1987/Catel/downloads","issues_url":"https://api.github.com/repos/szogun1987/Catel/issues{/number}","pulls_url":"https://api.github.com/repos/szogun1987/Catel/pulls{/number}","milestones_url":"https://api.github.com/repos/szogun1987/Catel/milestones{/number}","notifications_url":"https://api.github.com/repos/szogun1987/Catel/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/szogun1987/Catel/labels{/name}","releases_url":"https://api.github.com/repos/szogun1987/Catel/releases{/id}","deployments_url":"https://api.github.com/repos/szogun1987/Catel/deployments","created_at":"2016-06-23T19:31:34Z","updated_at":"2016-06-23T19:31:41Z","pushed_at":"2016-07-30T08:33:37Z","git_url":"git://github.com/szogun1987/Catel.git","ssh_url":"git@github.com:szogun1987/Catel.git","clone_url":"https://github.com/szogun1987/Catel.git","svn_url":"https://github.com/szogun1987/Catel","homepage":"http://www.catelproject.com","size":20542,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"Catel:develop","ref":"develop","sha":"3ed3101b3ebb8804ccbecb49d91bbf657e1c6e29","user":{"login":"Catel","id":4129749,"avatar_url":"https://avatars.githubusercontent.com/u/4129749?v=3","gravatar_id":"","url":"https://api.github.com/users/Catel","html_url":"https://github.com/Catel","followers_url":"https://api.github.com/users/Catel/followers","following_url":"https://api.github.com/users/Catel/following{/other_user}","gists_url":"https://api.github.com/users/Catel/gists{/gist_id}","starred_url":"https://api.github.com/users/Catel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Catel/subscriptions","organizations_url":"https://api.github.com/users/Catel/orgs","repos_url":"https://api.github.com/users/Catel/repos","events_url":"https://api.github.com/users/Catel/events{/privacy}","received_events_url":"https://api.github.com/users/Catel/received_events","type":"Organization","site_admin":false},"repo":{"id":9501756,"name":"Catel","full_name":"Catel/Catel","owner":{"login":"Catel","id":4129749,"avatar_url":"https://avatars.githubusercontent.com/u/4129749?v=3","gravatar_id":"","url":"https://api.github.com/users/Catel","html_url":"https://github.com/Catel","followers_url":"https://api.github.com/users/Catel/followers","following_url":"https://api.github.com/users/Catel/following{/other_user}","gists_url":"https://api.github.com/users/Catel/gists{/gist_id}","starred_url":"https://api.github.com/users/Catel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Catel/subscriptions","organizations_url":"https://api.github.com/users/Catel/orgs","repos_url":"https://api.github.com/users/Catel/repos","events_url":"https://api.github.com/users/Catel/events{/privacy}","received_events_url":"https://api.github.com/users/Catel/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Catel/Catel","description":"An application development platform","fork":false,"url":"https://api.github.com/repos/Catel/Catel","forks_url":"https://api.github.com/repos/Catel/Catel/forks","keys_url":"https://api.github.com/repos/Catel/Catel/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Catel/Catel/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Catel/Catel/teams","hooks_url":"https://api.github.com/repos/Catel/Catel/hooks","issue_events_url":"https://api.github.com/repos/Catel/Catel/issues/events{/number}","events_url":"https://api.github.com/repos/Catel/Catel/events","assignees_url":"https://api.github.com/repos/Catel/Catel/assignees{/user}","branches_url":"https://api.github.com/repos/Catel/Catel/branches{/branch}","tags_url":"https://api.github.com/repos/Catel/Catel/tags","blobs_url":"https://api.github.com/repos/Catel/Catel/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Catel/Catel/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Catel/Catel/git/refs{/sha}","trees_url":"https://api.github.com/repos/Catel/Catel/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Catel/Catel/statuses/{sha}","languages_url":"https://api.github.com/repos/Catel/Catel/languages","stargazers_url":"https://api.github.com/repos/Catel/Catel/stargazers","contributors_url":"https://api.github.com/repos/Catel/Catel/contributors","subscribers_url":"https://api.github.com/repos/Catel/Catel/subscribers","subscription_url":"https://api.github.com/repos/Catel/Catel/subscription","commits_url":"https://api.github.com/repos/Catel/Catel/commits{/sha}","git_commits_url":"https://api.github.com/repos/Catel/Catel/git/commits{/sha}","comments_url":"https://api.github.com/repos/Catel/Catel/comments{/number}","issue_comment_url":"https://api.github.com/repos/Catel/Catel/issues/comments{/number}","contents_url":"https://api.github.com/repos/Catel/Catel/contents/{+path}","compare_url":"https://api.github.com/repos/Catel/Catel/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Catel/Catel/merges","archive_url":"https://api.github.com/repos/Catel/Catel/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Catel/Catel/downloads","issues_url":"https://api.github.com/repos/Catel/Catel/issues{/number}","pulls_url":"https://api.github.com/repos/Catel/Catel/pulls{/number}","milestones_url":"https://api.github.com/repos/Catel/Catel/milestones{/number}","notifications_url":"https://api.github.com/repos/Catel/Catel/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Catel/Catel/labels{/name}","releases_url":"https://api.github.com/repos/Catel/Catel/releases{/id}","deployments_url":"https://api.github.com/repos/Catel/Catel/deployments","created_at":"2013-04-17T16:07:56Z","updated_at":"2016-07-23T06:00:56Z","pushed_at":"2016-07-30T08:42:11Z","git_url":"git://github.com/Catel/Catel.git","ssh_url":"git@github.com:Catel/Catel.git","clone_url":"https://github.com/Catel/Catel.git","svn_url":"https://github.com/Catel/Catel","homepage":"http://www.catelproject.com","size":24212,"stargazers_count":199,"watchers_count":199,"language":"C#","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":84,"mirror_url":null,"open_issues_count":3,"forks":84,"open_issues":3,"watchers":199,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/Catel/Catel/pulls/101"},"html":{"href":"https://github.com/Catel/Catel/pull/101"},"issue":{"href":"https://api.github.com/repos/Catel/Catel/issues/101"},"comments":{"href":"https://api.github.com/repos/Catel/Catel/issues/101/comments"},"review_comments":{"href":"https://api.github.com/repos/Catel/Catel/pulls/101/comments"},"review_comment":{"href":"https://api.github.com/repos/Catel/Catel/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Catel/Catel/pulls/101/commits"},"statuses":{"href":"https://api.github.com/repos/Catel/Catel/statuses/ac043425012713775c830693d41103912dab1921"}}}}
{"actor":{"display_login":"szogun1987"}}