Date
1 - 5 of 5
Response.write issue on bluemix
Gayathri Raghavendra prasad <graghav@...>
Hello,
I wrote a simple app which writes continuous chunks of data using response.write. The code is below. This works fine when I run it locally but the output never shows when the app runs on bluemix. The CF version on Bluemix : CF210.2 . Will appreciate any help on why this behavior. var app = require('express')(), http = require('http'); app.get('/', function(req, res){ var timer = setInterval(function () { res.write('Hellooo\n\n') res.write('Hiii\n\n') }, 2000) res.on('close', function () { clearInterval(timer) }) }); http.createServer(app).listen(process.env.VCAP_APP_PORT || '2000', function(){ console.log('Express server listening on port '+(process.env.VCAP_APP_PORT || '2000')); }); Thanks, Gayathri |
|
Yitao Jiang
I just deployed an application using your code . LGTM and BTW the same
release with you On Wed, Jul 8, 2015 at 5:57 AM, Gayathri Raghavendra prasad < graghav(a)us.ibm.com> wrote: Hello, -- Regards, Yitao(依涛 姜) jiangyt.github.io |
|
Gayathri Raghavendra prasad <graghav@...>
Thank you! I am getting the response after certain delay (i.e, after the
toggle quoted message
Show quoted text
buffer is full) and not after every 2 seconds.Could you please confirm if you are able to see the response every 2 seconds? Thanks, Gayathri From: Yitao Jiang <jiangyt.cn(a)gmail.com> To: "Discussions about Cloud Foundry projects and the system overall." <cf-dev(a)lists.cloudfoundry.org>, Date: 07/07/2015 10:26 PM Subject: Re: [cf-dev] Response.write issue on bluemix Sent by: cf-dev-bounces(a)lists.cloudfoundry.org I just deployed an application using your code . LGTM and BTW the same release with you On Wed, Jul 8, 2015 at 5:57 AM, Gayathri Raghavendra prasad <
graghav(a)us.ibm.com> wrote: Hello, I wrote a simple app which writes continuous chunks of data using response.write. The code is below. This works fine when I run it locally but the output never shows when the app runs on bluemix. The CF version on Bluemix : CF210.2 . Will appreciate any help on why this behavior. var app = require('express')(), http = require('http'); app.get('/', function(req, res){ var timer = setInterval(function () { res.write('Hellooo\n\n') res.write('Hiii\n\n') }, 2000) res.on('close', function () { clearInterval(timer) }) }); http.createServer(app).listen(process.env.VCAP_APP_PORT || '2000', function(){ console.log('Express server listening on port '+(process.env.VCAP_APP_PORT || '2000')); }); Thanks, Gayathri _______________________________________________ cf-dev mailing list cf-dev(a)lists.cloudfoundry.org https://lists.cloudfoundry.org/mailman/listinfo/cf-dev -- Regards, Yitao(依涛 姜) jiangyt.github.io_______________________________________________ cf-dev mailing list cf-dev(a)lists.cloudfoundry.org https://lists.cloudfoundry.org/mailman/listinfo/cf-dev |
|
Yitao Jiang
Yes, under firefox esr 38.01, it works just as expected every 2 seconds
On Wed, Jul 8, 2015 at 1:56 PM, Gayathri Raghavendra prasad < graghav(a)us.ibm.com> wrote: Thank you! I am getting the response after certain delay (i.e, after the -- Regards, Yitao(依涛 姜) jiangyt.github.io |
|
Gayathri Raghavendra prasad <graghav@...>
Thanks again! I have deployed the same app in my Bluemix environment and
toggle quoted message
Show quoted text
seeing a delay in the response till buffer is getting full. CF version as I mentioned earlier is CF210.2 and express package is latest. Can you please help as what other parameters in my environment might be causing this? Here is the url for my app : http://writedata-blue2.stage1.mybluemix.net/ Thanks, Gayathri From: Yitao Jiang <jiangyt.cn(a)gmail.com> To: "Discussions about Cloud Foundry projects and the system overall." <cf-dev(a)lists.cloudfoundry.org>, Date: 07/08/2015 01:38 AM Subject: Re: [cf-dev] Response.write issue on bluemix Sent by: cf-dev-bounces(a)lists.cloudfoundry.org Yes, under firefox esr 38.01, it works just as expected every 2 seconds On Wed, Jul 8, 2015 at 1:56 PM, Gayathri Raghavendra prasad <
graghav(a)us.ibm.com> wrote: Thank you! I am getting the response after certain delay (i.e, after the buffer is full) and not after every 2 seconds.Could you please confirm if you are able to see the response every 2 seconds? Thanks, Gayathri From: Yitao Jiang <jiangyt.cn(a)gmail.com> To: "Discussions about Cloud Foundry projects and the system overall." <cf-dev(a)lists.cloudfoundry.org>, Date: 07/07/2015 10:26 PM Subject: Re: [cf-dev] Response.write issue on bluemix Sent by: cf-dev-bounces(a)lists.cloudfoundry.org I just deployed an application using your code . LGTM and BTW the same release with you On Wed, Jul 8, 2015 at 5:57 AM, Gayathri Raghavendra prasad < graghav(a)us.ibm.com> wrote: Hello, I wrote a simple app which writes continuous chunks of data using response.write. The code is below. This works fine when I run it locally but the output never shows when the app runs on bluemix. The CF version on Bluemix : CF210.2 . Will appreciate any help on why this behavior. var app = require('express')(), http = require('http'); app.get('/', function(req, res){ var timer = setInterval(function () { res.write('Hellooo\n\n') res.write('Hiii\n\n') }, 2000) res.on('close', function () { clearInterval(timer) }) }); http.createServer(app).listen(process.env.VCAP_APP_PORT || '2000', function(){ console.log('Express server listening on port '+(process.env.VCAP_APP_PORT || '2000')); }); Thanks, Gayathri _______________________________________________ cf-dev mailing list cf-dev(a)lists.cloudfoundry.org https://lists.cloudfoundry.org/mailman/listinfo/cf-dev -- Regards, Yitao(依涛 姜) jiangyt.github.io_______________________________________________ cf-dev mailing list cf-dev(a)lists.cloudfoundry.org https://lists.cloudfoundry.org/mailman/listinfo/cf-dev _______________________________________________ cf-dev mailing list cf-dev(a)lists.cloudfoundry.org https://lists.cloudfoundry.org/mailman/listinfo/cf-dev -- Regards, Yitao(依涛 姜) jiangyt.github.io_______________________________________________ cf-dev mailing list cf-dev(a)lists.cloudfoundry.org https://lists.cloudfoundry.org/mailman/listinfo/cf-dev |
|