{"action":"created","issue":{"url":"https://api.github.com/repos/nrwiersma/ConfigManager/issues/11","repository_url":"https://api.github.com/repos/nrwiersma/ConfigManager","labels_url":"https://api.github.com/repos/nrwiersma/ConfigManager/issues/11/labels{/name}","comments_url":"https://api.github.com/repos/nrwiersma/ConfigManager/issues/11/comments","events_url":"https://api.github.com/repos/nrwiersma/ConfigManager/issues/11/events","html_url":"https://github.com/nrwiersma/ConfigManager/issues/11","id":242904941,"number":11,"title":"Memory usage and JSON/architectural issues","user":{"login":"JonSilver","id":8831106,"avatar_url":"https://avatars1.githubusercontent.com/u/8831106?v=4","gravatar_id":"","url":"https://api.github.com/users/JonSilver","html_url":"https://github.com/JonSilver","followers_url":"https://api.github.com/users/JonSilver/followers","following_url":"https://api.github.com/users/JonSilver/following{/other_user}","gists_url":"https://api.github.com/users/JonSilver/gists{/gist_id}","starred_url":"https://api.github.com/users/JonSilver/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JonSilver/subscriptions","organizations_url":"https://api.github.com/users/JonSilver/orgs","repos_url":"https://api.github.com/users/JonSilver/repos","events_url":"https://api.github.com/users/JonSilver/events{/privacy}","received_events_url":"https://api.github.com/users/JonSilver/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2017-07-14T05:59:52Z","updated_at":"2017-08-18T07:41:34Z","closed_at":"2017-08-17T16:26:16Z","body":"Hi @nrwiersma,\r\n\r\nFirstly thank you for taking the time to write and share this library. Unfortunately I've stopped using it for the moment as it introduced instability problems into my application, due to memory usage. So I was wondering about some of the architectural choices made with this library. Please correct me if I'm wrong with anything I say here.\r\n\r\nI've modified your library to use server->streamFile() instead of server->send(), so the HTML file is streamed directly from flash instead of being read into a string variable before being sent. This has both improved web server performance and reduced impact on heap space, in turn reducing crashes when the HTML file is too big.\r\n\r\nI'm also concerned about the security problems of the REST API. Since parameters may include passwords for MQTT brokers, having an open endpoint which freely shows clear text parameter values is a bit of a risk.\r\n\r\nThe library passes parameters via the REST API using JSON. This creates a large memory overhead and makes it difficult to use standard HTML forms for the PUT, as there is no JSON support built into HTML. Could we not just post server args using multipart/form-data and access each arg without the expensive transformation to and from JSON? Sure it makes it easy on the client where we have the convenience of JavaScript and Ajax, but it's expensive on the ESP8266 side.\r\n\r\nThanks,\r\nJon\r\n"},"comment":{"url":"https://api.github.com/repos/nrwiersma/ConfigManager/issues/comments/323283627","html_url":"https://github.com/nrwiersma/ConfigManager/issues/11#issuecomment-323283627","issue_url":"https://api.github.com/repos/nrwiersma/ConfigManager/issues/11","id":323283627,"user":{"login":"nrwiersma","id":644536,"avatar_url":"https://avatars3.githubusercontent.com/u/644536?v=4","gravatar_id":"","url":"https://api.github.com/users/nrwiersma","html_url":"https://github.com/nrwiersma","followers_url":"https://api.github.com/users/nrwiersma/followers","following_url":"https://api.github.com/users/nrwiersma/following{/other_user}","gists_url":"https://api.github.com/users/nrwiersma/gists{/gist_id}","starred_url":"https://api.github.com/users/nrwiersma/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nrwiersma/subscriptions","organizations_url":"https://api.github.com/users/nrwiersma/orgs","repos_url":"https://api.github.com/users/nrwiersma/repos","events_url":"https://api.github.com/users/nrwiersma/events{/privacy}","received_events_url":"https://api.github.com/users/nrwiersma/received_events","type":"User","site_admin":false},"created_at":"2017-08-18T07:41:34Z","updated_at":"2017-08-18T07:41:34Z","body":"Hi,\r\n\r\nWas looking into the POST request, and I remember why I chose JSON. The server args always returns a string, so typing is an issue. Will need to look into converting types."}}
{"actor":{"display_login":"nrwiersma"}}