{"action":"created","issue":{"url":"https://api.github.com/repos/yaobinshi/test1/issues/245","labels_url":"https://api.github.com/repos/yaobinshi/test1/issues/245/labels{/name}","comments_url":"https://api.github.com/repos/yaobinshi/test1/issues/245/comments","events_url":"https://api.github.com/repos/yaobinshi/test1/issues/245/events","html_url":"https://github.com/yaobinshi/test1/issues/245","id":53375720,"number":245,"title":"replace the current license list facility with a new batch agent to generate report and store as a file","user":{"login":"yaobinshi","id":8425217,"avatar_url":"https://avatars.githubusercontent.com/u/8425217?v=3","gravatar_id":"","url":"https://api.github.com/users/yaobinshi","html_url":"https://github.com/yaobinshi","followers_url":"https://api.github.com/users/yaobinshi/followers","following_url":"https://api.github.com/users/yaobinshi/following{/other_user}","gists_url":"https://api.github.com/users/yaobinshi/gists{/gist_id}","starred_url":"https://api.github.com/users/yaobinshi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yaobinshi/subscriptions","organizations_url":"https://api.github.com/users/yaobinshi/orgs","repos_url":"https://api.github.com/users/yaobinshi/repos","events_url":"https://api.github.com/users/yaobinshi/events{/privacy}","received_events_url":"https://api.github.com/users/yaobinshi/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/yaobinshi/test1/labels/Category%3A+Reporting+agent","name":"Category: Reporting agent","color":"ededed"},{"url":"https://api.github.com/repos/yaobinshi/test1/labels/Component%3A+Rank","name":"Component: Rank","color":"fad8c7"},{"url":"https://api.github.com/repos/yaobinshi/test1/labels/Component%3A+Tester","name":"Component: Tester","color":"fad8c7"},{"url":"https://api.github.com/repos/yaobinshi/test1/labels/Priority%3A+High","name":"Priority: High","color":"009800"},{"url":"https://api.github.com/repos/yaobinshi/test1/labels/Status%3A+Closed","name":"Status: Closed","color":"009800"},{"url":"https://api.github.com/repos/yaobinshi/test1/labels/Tracker%3A+Feature","name":"Tracker: Feature","color":"5319e7"}],"state":"open","locked":false,"assignee":{"login":"yaobinshi","id":8425217,"avatar_url":"https://avatars.githubusercontent.com/u/8425217?v=3","gravatar_id":"","url":"https://api.github.com/users/yaobinshi","html_url":"https://github.com/yaobinshi","followers_url":"https://api.github.com/users/yaobinshi/followers","following_url":"https://api.github.com/users/yaobinshi/following{/other_user}","gists_url":"https://api.github.com/users/yaobinshi/gists{/gist_id}","starred_url":"https://api.github.com/users/yaobinshi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yaobinshi/subscriptions","organizations_url":"https://api.github.com/users/yaobinshi/orgs","repos_url":"https://api.github.com/users/yaobinshi/repos","events_url":"https://api.github.com/users/yaobinshi/events{/privacy}","received_events_url":"https://api.github.com/users/yaobinshi/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/yaobinshi/test1/milestones/3","labels_url":"https://api.github.com/repos/yaobinshi/test1/milestones/3/labels","id":917471,"number":3,"title":"2.3.0","description":null,"creator":{"login":"yaobinshi","id":8425217,"avatar_url":"https://avatars.githubusercontent.com/u/8425217?v=3","gravatar_id":"","url":"https://api.github.com/users/yaobinshi","html_url":"https://github.com/yaobinshi","followers_url":"https://api.github.com/users/yaobinshi/followers","following_url":"https://api.github.com/users/yaobinshi/following{/other_user}","gists_url":"https://api.github.com/users/yaobinshi/gists{/gist_id}","starred_url":"https://api.github.com/users/yaobinshi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yaobinshi/subscriptions","organizations_url":"https://api.github.com/users/yaobinshi/orgs","repos_url":"https://api.github.com/users/yaobinshi/repos","events_url":"https://api.github.com/users/yaobinshi/events{/privacy}","received_events_url":"https://api.github.com/users/yaobinshi/received_events","type":"User","site_admin":false},"open_issues":35,"closed_issues":0,"state":"open","created_at":"2014-12-30T09:15:49Z","updated_at":"2015-01-05T08:54:00Z","due_on":null,"closed_at":null},"comments":1,"created_at":"2015-01-05T08:54:00Z","updated_at":"2015-01-05T08:54:00Z","closed_at":null,"body":"---\n\n\nAuthor Name: **Mary Laser** \nOriginal Redmine Issue: 27, http://www.fossology.org/issues/27\nOriginal Date: 2012/02/06\nOriginal Assignee: larry shi\n\n---\n\nHi Larry,\r\nIt looks like this needs some more clarification.\r\n \r\nUse an agent (a license list module) for the background process.\r\nHaving an agent write to report_cache isn't a good idea.  The report_cache is just that, a report cache, not a repository for scan results.\r\n \r\nLet me recap:\r\n1) we can't create and display a license list in real time because:\r\n   1.1) it takes too long to generate the list for more than a few thousand files.  I think this is mostly due to resolving the file path names.\r\n   1.2) it takes too long to send and render more than a few thousand lines in a browser.\r\n \r\nThis means that we have to either do it batch or do small lists in real time and larger ones batch.  For simplicity of the UI, I vote for doing them all batch.  Hence, we need a license list module, agent, and UI.\r\n[larry] that means we will add a new module ./src/licenselist, include agents and ui, right?\r\n\r\nYes.\r\n   2.2) When the user clicks on \"License List\", queue the job, display the job link, but leave the user on the license browser page.  This may be best done with a popup.\r\n[larry] my suggestion is: when the user click on “License List”\r\na)      If the list is already created, just stay in the [browse] page (looks like /repo/?mod=browse&upload=4&folder=1&item=3&show=detail), the default page when you click on  a package, then download the list automatically.\r\nb)      If the list is not created, queue the job, leave the user on the job page(looks like /repo/?mod=showjobs&show=job&job=1).\r\nc)       Do not popup any window. The user can check if the job is done via the mail notification or check the job status manually.\r\n\r\nYou have to tell the user that the job was queued.\r\n\r\n\r\n \r\n3) Where should the agent store the license list?\r\nI recommend a new repo section \"licenselist\".  A side effect of this is that delagent needs to remove the list.\r\n[larry] one license list file looks like /srv/fossology/repository/ licenselist/uploadtree_pk.txt\r\n\r\nDon't use the uploadtree_pk by itself.   Upload tree's can have different license lists if done with different versions of the nomos.   \r\n\r\n\r\n\r\nWe will save the license list info in report_cache,\r\nThe key is the job link, looks like: /repo/?mod=showjobs&show=job&job=1\r\nThe value is the license list file, looks like: /srv/fossology/repository/ licenselist/uploadtree_pk.txt\r\nMake sense?\r\n\r\nNo.  The report_cache table is to cache reports, not save filenames.  The licenselist_ars table would contain enough information to find the file in the repo.\r\n\r\n\r\n\r\n4) How does a user know when the job is done?\r\n  4.1) The usual, scheduler email notification or user manually checks.  See the email from earlier today on email notification.  The license list agent needs to include a link to the results (see UI below).  This link will download the results.\r\n \r\n5) What does the license list UI do?\r\nThere are two parts to the UI, one is to process the link when someone clicks on \"license list\".  This code should look to see if a list has already been generated and if it has, download the file to the user.  We already have a common function to handle downloads.  If the list hasn't been generated, it queues the license list agent.\r\n \r\nComments?\r\n \r\n\n\n\n"},"comment":{"url":"https://api.github.com/repos/yaobinshi/test1/issues/comments/68681703","html_url":"https://github.com/yaobinshi/test1/issues/245#issuecomment-68681703","issue_url":"https://api.github.com/repos/yaobinshi/test1/issues/245","id":68681703,"user":{"login":"yaobinshi","id":8425217,"avatar_url":"https://avatars.githubusercontent.com/u/8425217?v=3","gravatar_id":"","url":"https://api.github.com/users/yaobinshi","html_url":"https://github.com/yaobinshi","followers_url":"https://api.github.com/users/yaobinshi/followers","following_url":"https://api.github.com/users/yaobinshi/following{/other_user}","gists_url":"https://api.github.com/users/yaobinshi/gists{/gist_id}","starred_url":"https://api.github.com/users/yaobinshi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yaobinshi/subscriptions","organizations_url":"https://api.github.com/users/yaobinshi/orgs","repos_url":"https://api.github.com/users/yaobinshi/repos","events_url":"https://api.github.com/users/yaobinshi/events{/privacy}","received_events_url":"https://api.github.com/users/yaobinshi/received_events","type":"User","site_admin":false},"created_at":"2015-01-05T08:54:00Z","updated_at":"2015-01-05T08:54:00Z","body":"---\n\nOriginal Redmine Comment\nAuthor Name: **Mary Laser** \nOriginal Date: 2011/11/11 01:09:10 +0000\n\n---\n\nIn our meeting tonight, Larry asked for clarification of the enhancement description.  Specifically, \"2.2 When the user clicks on \"License List\", queue the job, display the job link, but leave the user on the license browser page.\"  He noted that \"License List\" is on the Browse page not License Browser, and asks Bob to confirm.\r\n"}}