Handlling stdout/err in toolingapi

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Handlling stdout/err in toolingapi

Radim Kubacki
Hi,

I looked at pull request to suppress output to System.out and System.err but couldn't get it completely working. Basic idea is quite simple -

After this patch it is possible to get the output/error messages from the daemon using LongRunningOperation.setStandart{Output|Error} and nothing goes to System.out and err. But we lose messages printed directly to System.out/err in the daemon. For example those that are relayed from child process like in our SamplesToolingApiIntegrationTest."can use tooling API to run tasks". I think we need to fix this problem first before we apply the patch but I couldn't find the right way how to make it working so far. Any hints would be appreciated. 

BTW: tooling API creates one LoggingServiceRegistry in DefaultConnection and soon after that the second in ProviderConnection. I think the second is not necessary.

-Radim
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Handlling stdout/err in toolingapi

Radim Kubacki
On Sun, Oct 12, 2014 at 8:21 PM, Radim Kubacki <[hidden email]> wrote:
Hi,

I looked at pull request to suppress output to System.out and System.err but couldn't get it completely working. Basic idea is quite simple -

After this patch it is possible to get the output/error messages from the daemon using LongRunningOperation.setStandart{Output|Error} and nothing goes to System.out and err. But we lose messages printed directly to System.out/err in the daemon. For example those that are relayed from child process like in our SamplesToolingApiIntegrationTest."can use tooling API to run tasks". I think we need to fix this problem first before we apply the patch but I couldn't find the right way how to make it working so far. Any hints would be appreciated. 

Actually this was my mistake and I wasted several hours trying to find what I do wrong :-(
 
BTW: tooling API creates one LoggingServiceRegistry in DefaultConnection and soon after that the second in ProviderConnection. I think the second is not necessary.

-Radim

Loading...