{"action":"created","issue":{"url":"https://api.github.com/repos/fabiocaccamo/django-treenode/issues/8","repository_url":"https://api.github.com/repos/fabiocaccamo/django-treenode","labels_url":"https://api.github.com/repos/fabiocaccamo/django-treenode/issues/8/labels{/name}","comments_url":"https://api.github.com/repos/fabiocaccamo/django-treenode/issues/8/comments","events_url":"https://api.github.com/repos/fabiocaccamo/django-treenode/issues/8/events","html_url":"https://github.com/fabiocaccamo/django-treenode/issues/8","id":389383506,"node_id":"MDU6SXNzdWUzODkzODM1MDY=","number":8,"title":"Performance issues","user":{"login":"lambdamusic","id":3493663,"node_id":"MDQ6VXNlcjM0OTM2NjM=","avatar_url":"https://avatars3.githubusercontent.com/u/3493663?v=4","gravatar_id":"","url":"https://api.github.com/users/lambdamusic","html_url":"https://github.com/lambdamusic","followers_url":"https://api.github.com/users/lambdamusic/followers","following_url":"https://api.github.com/users/lambdamusic/following{/other_user}","gists_url":"https://api.github.com/users/lambdamusic/gists{/gist_id}","starred_url":"https://api.github.com/users/lambdamusic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lambdamusic/subscriptions","organizations_url":"https://api.github.com/users/lambdamusic/orgs","repos_url":"https://api.github.com/users/lambdamusic/repos","events_url":"https://api.github.com/users/lambdamusic/events{/privacy}","received_events_url":"https://api.github.com/users/lambdamusic/received_events","type":"User","site_admin":false},"labels":[{"id":888834929,"node_id":"MDU6TGFiZWw4ODg4MzQ5Mjk=","url":"https://api.github.com/repos/fabiocaccamo/django-treenode/labels/enhancement","name":"enhancement","color":"a2eeef","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-12-10T16:33:28Z","updated_at":"2018-12-15T09:32:20Z","closed_at":null,"author_association":"NONE","body":"Been trying to create a few thousand items without any hierarchy infos, like this:\r\n\r\n```\r\n\r\n# models.py\r\n\r\nclass Customer(TreeNodeModel):\r\n\r\n    treenode_display_field = 'name'\r\n    name = models.CharField(max_length=50)\r\n\r\n    class Meta(TreeNodeModel.Meta):\r\n        verbose_name = 'Customer'\r\n        verbose_name_plural = 'Customer'\r\n\r\n# script.py\r\n\r\nfor x in names:\r\n    obj, created = Customer.objects.get_or_create(name=x)\r\n```\r\n\r\nBut the DB becomes incredibly slow after a couple hundred rows eg\r\n\r\n```\r\n[treenode] update bpids.models.Customer tree: executed 0 queries in 1.9379002410000226s.\r\n[treenode] update bpids.models.Customer tree: executed 0 queries in 1.9850395860000276s.\r\n[treenode] update bpids.models.Customer tree: executed 0 queries in 2.2034165819999885s.\r\n[treenode] update bpids.models.Customer tree: executed 0 queries in 2.5427609600000096s.\r\n[treenode] update bpids.models.Customer tree: executed 0 queries in 2.6210373019999906s.\r\n[treenode] update bpids.models.Customer tree: executed 0 queries in 3.163530485000024s.\r\n[treenode] update bpids.models.Customer tree: executed 0 queries in 1.538068753999994s.\r\n```\r\n\r\nSo totally unusable... \r\n\r\nAnything I'm doing wrong? "},"comment":{"url":"https://api.github.com/repos/fabiocaccamo/django-treenode/issues/comments/447553726","html_url":"https://github.com/fabiocaccamo/django-treenode/issues/8#issuecomment-447553726","issue_url":"https://api.github.com/repos/fabiocaccamo/django-treenode/issues/8","id":447553726,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0NzU1MzcyNg==","user":{"login":"fabiocaccamo","id":1035294,"node_id":"MDQ6VXNlcjEwMzUyOTQ=","avatar_url":"https://avatars3.githubusercontent.com/u/1035294?v=4","gravatar_id":"","url":"https://api.github.com/users/fabiocaccamo","html_url":"https://github.com/fabiocaccamo","followers_url":"https://api.github.com/users/fabiocaccamo/followers","following_url":"https://api.github.com/users/fabiocaccamo/following{/other_user}","gists_url":"https://api.github.com/users/fabiocaccamo/gists{/gist_id}","starred_url":"https://api.github.com/users/fabiocaccamo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fabiocaccamo/subscriptions","organizations_url":"https://api.github.com/users/fabiocaccamo/orgs","repos_url":"https://api.github.com/users/fabiocaccamo/repos","events_url":"https://api.github.com/users/fabiocaccamo/events{/privacy}","received_events_url":"https://api.github.com/users/fabiocaccamo/received_events","type":"User","site_admin":false},"created_at":"2018-12-15T09:32:20Z","updated_at":"2018-12-15T09:32:20Z","author_association":"OWNER","body":"@lambdamusic ok, let me know!"}}
{"actor":{"display_login":"fabiocaccamo"}}