How to stop GStreamer DEBUG logs - gstreamer

I am enabling GST_DEBUG = 7 and then starting a media application, so I keep on getting the logs which I have set as "GST_DEBUG_FILE":"/var/log/gst-log".
Q. If I close the media application I stop getting the logs(which is fine), but is there any way to stop the GST_DEBUG logs using CLI ?
Please correct me if my thought process is not in right direction, I am new to this.

If I understand correctly, you would like to change the value of GST_DEBUG environment variable when GStreamer process is running. If so, in general you can't do that. There are however some ways to overcome that. Look at this and this question.

Related

Property cupertinoCalculateChunkIDBasedOnTimecode in Wowza

I am using Wowza Engine 4.5.0 and I am trying to change the chunk ID numbering based on incoming packet time, instead of the default sequential number that cause problems when restarting the encoder.
From something like this
...media_w112312312_b1024000_7.ts
...media_w112312312_b1024000_8.ts
to a timestamp notation where the chunks continue even after a restart
I read about the property cupertinoCalculateChunkIDBasedOnTimecode, I follow the instructions in this guide to configure it:
https://www.wowza.com/docs/how-to-configure-apple-hls-packetization-cupertinostreaming#livepropref
but it does not work or I am doing something wrong. Has anyone used the property
cupertinoCalculateChunkIDBasedOnTimecode successfully?
many thanks
I have used 'cupertinoCalculateChunkIDBasedOnTimecode' property and even if I restart my encoder, players are able to pick up the stream and play successfully.
The below page will help you in using it properly
http://thewowza.guru/how-to-set-stream-timecodes-to-absolute-time/

Cannot use WebStorm console in 'live' mode

How do I view/peruse objects in WebStorm in console live mode?
In Chrome, when I am sitting on a breakpoint, I can type something into the console like so :
myObject.myVal[0].elem
However when I am in WebStorm, sitting on a breakpoint on one of my tests, I open the console, but I cannot type into the console!! I cannot see any objects.
It just looks like this :
I seem to remember it used to be able to do something like this. Is there some setting somewhere that I need to set?
[..Update..]
Yes, I was right. It was possible for me to do this in the past :
https://blog.jetbrains.com/phpstorm/2014/07/new-live-console-in-javascript-and-node-js-debugger/
This seems not to work for me anymore, or it is broken when running tests.
It makes WebStorm pretty useless for me at the moment.
'Live' mode is not available in Test Frameworks Console; please vote for WEB-20297 to be notified on any progress with this feature

Failed to execute: 'control update-cluster' for /var/lib/openshift/<user_id>/haproxy

I can't restart, force stop, remove cartridges, delete the application, see the logs or add new keys. Basically I can do nothing. I think my app is corrupted somehow. I would like to delete this one and create a new one but in the future, if this happens again I would like to understand why.
I had a similar problem 2 days ago, and I was not the only one.
In my case the problem was fixed the next day without any intervention of my own.
Take a look here for more info : Can't start/stop openshift application

Selenium wait for download?

I'm trying to test the happy-path for a piece of code which takes a long time to respond, and then begins writing a file to the response output stream, which prompts a download dialog in browsers.
The problem is that this process has failed in the past, throwing an exception after this long amount of work. Is there a way in selenium to wait-for-download or equivalent?
I could throw in a Thread.sleep, but that would be inaccurate and unnecessarily slow down the test run.
What should I do, here?
I had the same problem. I invented something to solve the problem. A tempt file is created by Python with '.part' extension. So, if still we have the temp, python can wait for 10 second and check again if the file is downloaded or not yet.
while True:
if os.path.isfile('ts.csv.part'):
sleep(10)
elif os.path.isfile('ts.csv'):
break
else:
sleep(10)
driver.close()
So you have two problems here:
You need to cause the browser to download the file
You need to measure when the downloaded file is complete
Neither problemc an be directly solved by Selenium (yet - 2.0 may help), but both are solvable problems. The first problem can be solved by GUI automation toolkits, such as AutoIT. But they can also be solved by simply sending an automated keypress at the OS level that simulates the enter key (works for Firefox, a little harder on some versions of Chrome and Safari). If you're using Java, you can use Robot to do that. Other languages have similar toolkits to do such a thing.
The second issue is probably best solved with some sort of proxy solution. For example, if your browser was configured to go through a proxy and that proxy had an API, you could query the proxy with that API to ask when network activity had ended.
That's what we do at http://browsermob.com, which is a a startup I founded that uses Selenium to do load testing. We've released some of the proxy code as open source, available at http://browsermob.com/tools.
But two problems still persist:
You need to configure the browser to use the proxy. In Selenium 2 this is easier, but it's possible to do it with Selenium 1 as well. The key is just making sure that your browser launcher brings up the browser with the right profile/settings.
There currently is no API for BrowserMob proxy to tell you when network traffic has stopped! This is a big hole in the concept of the project that I want to fix as soon as I get the time. However, if you're keen to help out, join the Google Group and I can definitely point you in the right direction.
Hope that helps you identify your various options. Best of luck!
This is Chrome-testing-only solution for controlling the downloads with javascript..
Using WebDriver (Selenium2) it can be done within Chrome's chrome:// which is HTML/CSS/Javascript:
driver.get( "chrome://downloads/" );
waitElement( By.CssSelector("#downloads-summary-text") );
// next javascript snippet cancels the last/current download
// if your test ends in file attachment downloading
// you'll very likely need this if you more re-instantiated tests left
((JavascriptExecutor)driver).executeScript("downloads.downloads_[0].cancel_();");
There are other Download.prototype.functions in "chrome://downloads/downloads.js"
This suites you if you just need to test some info note eg. caused by file attachment starting activity, and not the file itself.
Naturally you need to control step 1. - mentioned by Patrick above - and by this you control step 2. FOR THE TEST, not for the functionality of actual file download completion / cancel.
See also : Javascript: Cancel/Stop Image Requests which is relating to Browser stopping.
This falls under the "things that can't be automated" category. Selenium is built with JavaScipt and due to JavaScript sandbox restrictions it can't access downloads.
Selenium 2 might be able to do this once Alerts/Prompts have been implemented but that this won't happen for the next little while yet.
If you want to check for the download dialog, try with AutoIt. I use that for uploading and downloading the files. Using AutoIt with Se RC is easier.
def file_downloaded?(file)
while File.file?(file) == false
p "File downloading in progress..."
sleep 1
end
end
*Ruby Syntax

Using OSSOLOG in scratchbox (maemo development)

I am building a sharing-service for maemo5. In the example plugin they are calling ULOG_INFO_L at a lot of places, so I have adopted this for my service as well. The problem is that I can't find where the messages goes.
Reading osso-log.h I should define DEBUG or OSSOLOGCOMPILE, which I do and OSSOLOG_STDOUT or OSSOLOG_SYSLOG. I have tried both settings but can't get anything on syslog or stdout (I have no idea where stdout should end up since I am only calling af-sb-init.sh start), and it's not there anyway :-)
Anyone know where I can find my log?
I found out that when using OSSOLOG_SYSLOG it actually logs to the host machine, not the scratchbox environment.