Track C++ application with google analytics - c++

Is a possibility to track my C++ application usage using google analytics?

to track application usage with google analytics is necessary to generate http request to this url:
*
http://www.google-analytics.com/__utm.gif?
utmwv=3&
utmn=<random number>&
utme=&
utmcs=ISO-8859-1&
utmsr=1280x1024&
utmsc=24-bit&
utmul=en-us&
utmje=1&
utmfl=-&
utmhn=<www.stopka.us>&
utmhid=2112093191&
utmr=-&
utmp=/login.php?user=12&
utmac=UA-XXXXX-1&
utmcc=__utma%3D1.<unique id>.<time (in sec's since Jan 1, 1970) of first
visit).<time of last visit>.<time of current visit>.<visit count>%3B
%2B
__utmz%3D1.1203103189.1.1.utmcsr%3D<source>%7Cutmccn%3D<campaign>
%7Cutmcmd%3D<medium>%3B
*
all parameters is possible to fill with it's user env. values.
This way is not convenient enough.
So, I create my own library. I call it UsageAnalytics and distribute it as open source project at: http://code.google.com/p/usageanalytics/
thanks for all for participation, thanks for me for the library.
btw. cause code.google.com outdated, I've moved that stuff to
https://github.com/vyemialyanchyk/usageanalytics

By now you may have already solved your need, but for what it's worth, my firm has also released a C library supporting Google's Universal Analytics Measurement Protocol.
https://github.com/analytics-pros/universal-analytics-c
Good luck!

Google has a library for accessing Analytics API from C++, it's in "alpha", but it looks like what you want... https://developers.google.com/api-client-library/cpp/apis/analytics/v2.4

The best library I found for tracking analytics with c++ is this unofficial one on github: https://github.com/HSAnet/qt-google-analytics
Note however that it has Qt as a dependency...

If you want to track C++ Android or iOS apps you could use Google's Firebase:
https://firebase.google.com/docs/analytics/cpp/start

Old question, but nowadays more and more developers are starting to use usage analytics for their software.
"SoftMeter", a library I created myself, is my solution to this need.
It has a native C and C++ interface.
https://www.starmessagesoftware.com/softmeter/sdk-api

Related

Web Services using C++

I am building a server-client application that involves heavy signal processing (e.g. FFT). I have a working application written in C++/Qt, where everything (signal processing and other calculations) is done in client and server just sends raw data. Now I feel it would be easier to implement these features on the server. So, that maintenance becomes easier.
As I am doing signal processing, I think I should stick to C++ for performance. But I am open to new ideas.
Constraints:
I need type checking so javascript is out of discussion.
Scaling includes adding more server and each server will have at the max
10-12 users. So, Hardware cost is important. I cannot use x number of
i7 processors.
No option of using cloud services.
So, right now my question is as follows:
How can I create web services using C++ for Linux server? (Although cross platform is not important, I would appreciate if I can achieve it.)
EDIT [02:09:2015]
Right now, I think the choice is between poco and C++ Rest SDK. I feel I should go for C++ Rest SDK. Mainly because it has only those features that I need. And Also it is supported by microsoft and uses boost internally. So, I feel in future, this might be well integreated with standard.
You could use cross-platform Poco library to implement HTTP server, it is really straightforward with this framework, and they have a lot of examples. You can also use JSON serialization (like rapidjson library) to implement REST service on top of HTTP - this way your Web service will be accesable by most of the modern Web frameworks.
You might want to take a look at the C++ Rest SDK, an open source, cross platform API from Microsoft.
Like #nogard suggested, I also recommend POCO for now. It's the most serious and feature-full solution. Given you mentioned Qt, I suggest you to take a look at Tufão.
EDIT:
I forgot to mention one comparison of mine on the C++ HTTP server frameworks.
If you directly handle HTTP requests, you might loose the functionality what Web Servers does well what it was build to do. I had a similar issue, what I did was wrap up my Qt c++ code inside a PHP extension. In your case you can do the same. Wrap your logic inside what ever technology you are about to use, doesn't matter it's PHP, net , Java or anything else.

What is the best way to integrate Google Analytics into a C++ OpenFrameworks desktop project?

I'm currently building an OpenFrameworks project and need to use Google Analytics to track user interactions. I have yet to find any existing C++ libraries for doing so, and am considering writing my own. Is the API open enough to allow a custom library to be created? If one doesn't exist, any ideas on where to begin coding my own?
Yes it is possible and easy to extend openframeworks!
You can look here if there is an addon which fits your need. Maybe ofxCurl or ofxHttpUtils are the right ones to create an request like the one mentioned in the comment by yahelc.
If you don't find a solution there, you can look here to find first informations about creating addons for openFrameworks. If you have any further questions, please ask in the official openframeworks forums which you can find here.
Looks like you'll have to build your own solution... I'd use ofxHttpUtils to ping Google's Analytics API. You should also consider wrapping your work as an OF addon and sharing in openframewors.cc
I've built an OpenFrameworks add-on to do just that:
http://github.com/armadillu/ofxGoogleAnalytics

Looking for third party charting options for ColdFusion

A project I am working on makes extensive use of CFCHART. We have run into quite a few usage and performance issues with CFCHART, so I have been tasked to look at some third-party solutions to try out and recommend. Anybody have some reviews and recommendations they'd care to share?
Consider outputting the raw data and using JavaScript / Canvas to generate the charts on the fly. The load is the given to the client.
This makes it easier for screenreaders and people who like to save the data to access it as well.
Some JS charting libraries:
http://code.google.com/apis/chart/
http://omnipotent.net/jquery.sparkline/
http://code.google.com/p/flot/
http://codecanyon.net/item/graphup-jquery-plugin/108025?redirect_back=true&ref=1stwebdesigner&clickthrough_id=23945276
http://www.highcharts.com/
Not dependent on your server side technology (e.g. irrelevant to the fact that you're using CF), I have recently started playing around with HighCharts (http://www.highcharts.com/), and have been very impressed.
Bear in mind, it's not free for commercial use, but you didn't specify as to any such restrictions. Although their pricing seems pretty fair (see http://www.highcharts.com/license)
The Wijmo jQuery library has some nice charting widgets. http://wijmo.com/
We use FusionCharts. They have a comprehensive set of chart and widget types (eg sparklines) and have a very slick, professional finish.
ChartDirector is reasonable and is very advanced. It generates image-based graphs and we don't have to worry about whether or not different browsers support various advanced HTML features or Flash. You can download it, install and run it unlicensed and it will only add a little copyright in the bottom-right 20 pixels of the graph. (Licensing is inexpensive.) It comes with 239+ ColdFusion scripts so that you have plenty of sample code. Their support forums is very active and helpful.
http://www.advsofteng.com/cdcoldfusion.html
Check out the gallery. It has some very impressive samples. You can create just about anything.
http://www.advsofteng.com/gallery.html
You can try jqChart as well.
Thank you to everyone for these suggestions! This gives me a good list of applications to work with. Since there is no one "right" answer for a question like this I made sure to note each answer as useful.

Developing a facebook app with c++

I'm a computer science student with experience in C/C++ and I want to have a go at developing
a simple facebook app. Can anyone recommend a good website and/or editor?
Is it doable with C++ or do I need to learn another language?
Thanks
I assume that you are talking about an internet application.
For the front end (client side), you will need something to enhance your web pages (in Javascript, for example). For the back end (server side), you will need to make database queries so you will need to know SQL as well.
No, I don't think C/C++ is enough.
I would suggest that you investigate some other languages such as PHP or ASP.Net.
It sure is doable in C++. I recommend though that you first write a small Facebook client API in a scripting language so you can do some quick and dirty testing while getting familiar with how the API works. This will save you a lot of frustration when trying to write the C++ version.
As editor I recommend Visual C++ Express Edition if you are using Windows, XCode if you are using Mac, and on Linux I'd use Vim (if that is your cup of tea).
A good website? The Facebook API docs pages of course!
i Released c++ facebook graph api client as open source
check it out here :
facebook-cpp-graph-api
Python might be worth considering.
The Wiki might not be a bad place to start on it.
(There are a couple of link to Tutorials in there)
Facebook Developers Wiki
check this c++ graph api as open source you can download it and use it
its handling login/authentication sequence with the Qwebkit:
http://code.google.com/p/facebook-cpp-graph-api/

Controlling Firefox from C/C++

I'm thinking of creating an application that can use Firefox as a download manager. Is there any way to control Firefox (add downloads, start/stop downloads, etc) from an external program in C/C++?
If that is not possible, then perhaps an extension that can do that? If an extension is the only way, then how do I communicate with the extension from outside of Firefox?
You're starting with a solution, not a problem. The easier idea is to use XulRunner, the platform on which FireFox is built. You'd effectively implement your own application as a XulRunner plugin and use Necko (the network layer of XulRunner and FireFox) from there.
First of all I suggest that you familiarize yourself with developer.mozilla.org
As far as I understand, most Mozilla platform functions are available through a cross language API known as XPCOM. There's also a plugin API but it's primary aim is to visualize stuff (used by Flash, etc.).
Take a look at Gecko API. It allows third party developers to use the same technology as found in Mozilla.
For downloading files no need to use Firefox. Consider using libcurl.
Take a look at wget.