Friday, March 27, 2009

[Gd] Better know a service: InfoService

| More

AdWords API Blog: Better know a service: InfoService

We, at the AdWords API Team, are often asked questions such as "Where have all my units gone?" and "How many API units has a particular account used in the last month?" Luckily, we have supplied you with a great set of tools with InfoService to answer these questions. In this blog post, we'll talk about some basic uses of this service, as well as some caveats that can be solved using some more advanced techniques. All code examples have been coded using the AdWords Java Client Library.

Where have all my units gone?

"Where have all my units gone?" is one of the most frequent questions asked by our developers seeking to trim down their API usage. Although InfoService provides the method getUnitCountForMethod, it is not inherently obvious how to generate a full mapping of usage. The heart of the problem is that, to call getUnitCountForMethod, you must pass it a service name and method. To get a full mapping of method to usage, getUnitCountForMethod must be called for each service and method pair. In the example MethodQuotaUsageDemo, I have shown how you might do this.

The example is broken into two parts: populating a full mapping of service name to list of method names, and calling getUnitCountForMethod for each mapping. The result of each call is then put into a new map, referred to as
methodUsage in the example. When the example has finished running, which may take a few seconds, methodUsage will have a mapping of serviceName.methodName to quotaUsage and the output will resemble:

AccountService.getAccountInfo = 3
AccountService.getClientAccountInfos = 257
AccountService.getClientAccounts = 0
AccountService.getMccAlerts = 0
AccountService.updateAccountInfo = 0
...
AdService.addAds = 5005
AdService.checkAds = 0
AdService.findBusinesses = 0
AdService.getActiveAds = 0
AdService.getAd = 0
AdService.getAdStats = 0
AdService.getAllAds = 0
AdService.getMyBusinesses = 0
AdService.getMyVideos = 0
AdService.updateAds = 0
...
TrafficEstimatorService.checkKeywordTraffic = 0
TrafficEstimatorService.estimateAdGroupList = 0
TrafficEstimatorService.estimateCampaignList = 0
TrafficEstimatorService.estimateKeywordList = 0

As you can see, many of my units went towards adding Ads. Using this data, I could enter my monthly values into a spreadsheet and plot my usage over several months. Not only could I easily spot where all of my units have gone, but I would also be able to spot any out of the ordinary behavior as well.

As a side note, regardless of the credentials supplied to the service, this method will only gather data against the developer token. Meaning that, supplying a clientEmail or clientCustomerId will not give a finer grained set of results.

How many API units has a particular child account used in the last month?

Another great feature of InfoService is that it allows you to determine how many units a particular child account has used over a period of time. This information can be used to invoice clients, if you are developing for an Agency, or to perform cost/ctr analysis, if you wished to optimize your accounts per API spend.

There is one caveat, however. Let's say that we have an account structure that resembles the one below:




We have a top most MCC, Top-MCC, which is the root of our tree. Since our goal is to generate a mapping of child account to the amount of quota used, a first approach may be to run getUnitCountForClients for each client, as shown below:

InfoService.getUnitCountForClients(["Sub-MCC-1",
"Sub-MCC-2", "Client-1", "Client-2",
"Client-3", "Client-4"],
"3/1/2009", "3/31/2009");

From the results, you can create a mapping that resembles:

Sub-MCC-1 = 55
Sub-MCC-2 = 70
Client-1 = 500
Client-2 = 650
Client-3 = 600
Client-4 = 400

You'll notice that while this data gives you some idea of client usage, there's no aggregation of client usage up to the MCC; Sub-MCC-1 returns just the number of units called directly on that account, such as from a command with headers:

<email>Top-MCC</email>
<password>passwordForTop-MCC</password>
<developerToken>...</developerToken>
<applicationToken>...</applicationToken>
<userAgent>...</userAgent>
<clientEmail>Sub-MCC-1</clientEmail>

What you may actually want is an aggregation of unit usage such as:

Top-MCC = 2275
Sub-MCC-1 = 1305
Sub-MCC-2 = 470
Client-1 = 500
Client-2 = 650
Client-3 = 600
Client-4 = 400

In the example ClientQuotaUsageDemo, I show how to traverse the full account tree below the top most MCC and sum the units for each client to produce a mapping like the one above. However, if by some chance, a client has two parent accounts, linked through UI/API and API, and those parents are both distant children of the same parent, that client will be doubly counted. We've also shown how to keep track of these doubly counted clients in the demo.

We hope that these new examples will help you keep track of your API usage and stay tuned for more great demos like these!

--Adam Rogal, AdWords API Team
URL: http://adwordsapi.blogspot.com/2009/03/better-know-service-infoservice.html

[Gd] Tell us about your GWT applications and prototypes

| More

Google Web Toolkit Blog: Tell us about your GWT applications and prototypes

A common question that is asked when developers and IT managers first consider Google-Web-Toolkit is: Who's using it? There are a number of places where you can find a partial answer such our own App Gallery or the Google Code blog. The community has started its own lists as well, such as those here, here and here.



While we encourage you to share directly with the GWT community in the user forum, we realize some of you may prefer to give feedback more privately, perhaps because your company policies require you to. If you have a story you would like to share, we would love to hear about it. Just send me an email.



I look forward to hearing about your GWT projects and experiences.
URL: http://googlewebtoolkit.blogspot.com/2009/03/tell-us-about-your-gwt-applications-and.html

Thursday, March 26, 2009

[Gd] Helping your site look great with Google Chrome

| More

Official Google Webmaster Central Blog: Helping your site look great with Google Chrome

Webmaster Level: Intermediate to Advanced
Since launching Google Chrome last September, we received a number of questions from webmasters and web developers about how to make their sites look great in Google Chrome. The questions were very insightful and illuminating for the Chrome team, and I want to respond with a few helpful tips for making your site look stellar in Google Chrome.

Detecting Google Chrome

Most sites will render the same in both Safari and Google Chrome, because they're both WebKit-based browsers. If your site looks right in Safari, then it should look right in Google Chrome, too.

Since Chrome is relatively new, many sites have confused Google Chrome with another browser. If your site doesn't look quite right in Chrome but works fine in Safari, it's possible your site may just not recognize Chrome's user-agent string.

As platforms and browsers adopt WebKit as their rendering engine, your site can detect and support them automatically with the right JavaScript checks. Commonly, sites use JavaScript to 'sniff' the navigator.userAgent property for "Chrome" or "Safari", but you should use proper object detection if possible. In fact, Gmail has been detecting WebKit properly in Chrome since day one!

If you must detect the user-agent type, you can use this simple JavaScript to detect WebKit:

var isWebkit =
  navigator.userAgent.indexOf("AppleWebKit") > -1;


Or, if you want to check that the version of WebKit is at least a certain version—say, if you want to use a spiffy new WebKit feature:

var webkitVersion =
  parseFloat(navigator.userAgent.split("AppleWebKit/")[1]) ||
  undefined;
if (webkitVersion && webkitVersion > 500 ) {
  // use spiffy WebKit feature here
}


For reference, here are a few browser releases and the version of WebKit they shipped:

BrowserVersion of WebKit
Chrome 1.0525.19
Chrome 2.0 beta530.1
Safari 3.1525.19
Safari 3.2525.26.2
Safari 4.0 beta528.16


We do not recommend adding "Google" or "Apple" to your navigator.vendor checks to detect WebKit or Google Chrome, because this will not detect other WebKit or Chromium-based browsers!

You can find more information about detecting WebKit at webkit.org.

Other helpful tips
  • Google Chrome doesn't support ActiveX plug-ins, but does support NPAPI plug-ins. This means you can show plug-in content like Flash and Java in Google Chrome the same way you do with Firefox and Safari.
  • If text on your site looks a bit off, make sure you provide the proper content type and character encoding information in the HTTP response headers, or at the beginning of your pages, preferably near the top of the <head> section.
  • Don't put block elements inside inline elements.
Wrong:   <a><div>This will look wrong.</div></a>

Right:     <div><a>This will look right!</a></div>
  • If your JavaScript isn't working in Google Chrome, you can debug using Chrome's built-in JavaScript debugger, under the "page" menu -> 'Developer' -> 'Debug JavaScript' menu option.
To help webmasters and web developers find more answers, we created a support center and forum specifically to answer your questions. Of course, if you find something you think is really a bug in Chrome, please report it to us!

Help us improve Google Chrome!

If you'd like to help even more, we're looking for sites that may be interested in allowing Google to use their site as a benchmark for our internal compatibility and performance measurements. If you're interested in having Google Chrome development optimized against a cached version of your site, please contact us about details at chrome-webmasters@google.com.

Please keep the feedback coming, and we'll keep working to improve Google Chrome!

Written by Glenn Wilson, Product Manager, Google Chrome
URL: http://googlewebmastercentral.blogspot.com/2009/03/helping-your-site-look-great-with.html

[Gd] Custom Logos for Open Source Projects

| More

Google Code Blog: Custom Logos for Open Source Projects

Open source projects now have customizable logos! You can use this to maintain consistency with your other websites or just for fun. Here's an example of a project with its own logo. In the spirit of new logos, project hosting recently updated the default logo for projects to the flashy new computer shown above!

To update the logo on your project, click on the Administer tab (as long as you're a project owner) and upload an image. It will automatically be resized. You can switch back the default logo or upload a new logo at any point.

Google projects such as Chromium will retain the large Google logo.

For other notable changes, see our groups post.

By Andy Chu, Software Engineer, Google Code
URL: http://google-code-updates.blogspot.com/2009/03/custom-logos-for-open-source-projects.html

Wednesday, March 25, 2009

[Gd] Chromium and Google Summer of Code

| More

Chromium Blog: Chromium and Google Summer of Code

Time is quickly running out for the students to apply for this year's Google Summer of Code.

The Chromium project has been accepted as a mentoring organization for this awesome program. This means that over the summer, you have the opportunity to work on new and exciting features for Chromium (and supporting projects) and experience browser development first-hand with a mentor from the project and real deadlines.

Full guidelines and details on how to apply can be found on the official gsoc website. To participate, pick an idea off our handy list or suggest one of your own (it's best to discuss it with a mentor first), then write up a proposal on how you'd go about accomplishing the task in the allotted time frame (3 months).

You can find a list of suggested topics here. These are only recommendations though, feel free to stop by our mailing list or irc channel and suggest something new. If you do decide to write your own proposal, we're looking for familiarity with the codebase, and lots of intelligent detail. The more details you can provide, the better!

Student registration runs from the 23rd of March until the 3rd of April. We're looking forward to seeing the project submissions and expanding our community involvement.

Posted by Jeremy Moskovich, Software Engineer
URL: http://blog.chromium.org/2009/03/chromium-and-google-summer-of-code.html

[Gd] Google Services for Websites includes Custom Search

| More

Google Custom Search: Google Services for Websites includes Custom Search

Posted by: Radu Cornea, Software Engineer and Kevin Godzilla Lim, Technical Writer

As you may have read on the Official Google Blog, today, Google is launching Google Services for Websites, a new program that enables partners to offer Google services, including Custom Search, Site Search, Webmaster Tools, and AdSense, to their users.

Partners, such as web hosters and blogging platforms, can integrate these services into their own management consoles, making them easily accessible to their users. Google Services for Websites allows partners to create Google accounts, submit Sitemaps to Webmaster Tools, configure Custom Search, and provision new AdSense accounts on behalf of customers. Additionally, partners are also eligible for referral fees for certain services - a number of web hosting providers have already integrated these services into their offering.

Once Google Services for Websites has been integrated into your control panel, your users can configure their Google services in minutes. These services can help increase website traffic, provide site search, and monetize website content. Furthermore, all of these services are designed to complement and enhance one another. For example, Sitemaps submitted to Webmaster Tools not only improve the discoverability of websites to Google search, but also improve coverage in Custom Search and offer faster inclusion via On-Demand Indexing. AdSense accounts can also be associated with search, which lets website owners earn revenues with relevant ads displayed alongside search results.

To learn more about integrating Google Services for Websites with your services, read the Google Services for Websites program overview.

URL: http://googlecustomsearch.blogspot.com/2009/03/google-services-for-websites-includes.html

[Gd] Making more tools available with just a click

| More

Official Google Webmaster Central Blog: Making more tools available with just a click

Last July, we launched our Webmaster Tools Access Provider Program and it's been a huge hit. Hundreds of providers have signed up, and thousands of users now access Webmaster Tools via their provider's control panel.

Today we are launching the Google Services for Websites Access Provider Program which enable providers to offer the following features to site owners:
  • Enhance their site with Custom Search or Google Site Search
  • Monetize with AdSense
  • Optimize for search with Webmaster Tools

How can you get in on this?

Webmasters: Watch to see if your providers join this program, so the next time you manage your site, everything will be all set for you. Better yet, send your providers a link to this post and tell them we're here to help them help you.

Providers: Check out the Google Services for Websites site and sign up today!

And in case you're wondering, providers that have signed up for the Webmaster Tools Access Provider program will automatically be upgraded to the new program. Also, no worries for developers -- the backend Webmaster Tools APIs remain unchanged.

Posted by Sagar Kamdar, Product Manager

URL: http://googlewebmastercentral.blogspot.com/2009/03/making-more-tools-available-with-just.html

[Gd] Dev Channel Update: 2.0.171.0

| More

Google Chrome Releases: Dev Channel Update: 2.0.171.0

Google Chrome's Dev channel has been updated to 2.0.171.0.  Most of the focus this week has been on usability and stability fixes.  However, there are some new features available from command line switches.

Features:

  • New FTP implementation: use --new-ftp
  • Experimental Bookmark Menu: use --bookmark-menu
  • HTML5 Web Workers: use --enable-web-workers
  • Implement SSL renegotiation. (Issue: 6893)
  • Pressing the Del key while a item is selected in the form suggestion popup deletes that suggestion from the DB.
  • WebKit version 530.4
  • V8 version 1.1.1.4
Fixes:
  • Add command line switch "--new-ftp" for new portable FTP (Issue: 4965)
  • Add the directory listing code for the new portable FTP (Issue: 4965)
  • SSL improvements. (Issue: 8706)
  • Fix excessive CPU when scrolling Flash. (Issue: 8653)
  • Fix crash on showing info bubble. (Issue: 8854)
  • Aligning text to the right, especially RTL languages. (Issue: 1845)
  • Fix dragging a Chrome window which has a single tab by the tab itself. (Issues: 2827, 8287)
  • Do correct hit testing for context menu items. (Issue: 8100)
  • Add support for progressive JPEGs with MIME type image/pjpeg. (Issue: 2104)
Known Issues:
  • Issue 8892: Browser crash with closing about:network window.
  • Issue 8732: Provide a scroll bar for about:network dialog
  • Issue 8767: Can create multiple Downloads tabs from Download shelf
  • Issue 8220: No more status spinning in Downloads page
  • Issue 8637: Unable to drag window when one browser window open with single tab
  • Issue 8827: Import browsring history shows today's history only in the history page.
  • Issue 8822: Tab crashes with debugger !
  • Issue 8821: Inspector is broken, shows empty elements
  • Issue 8372: Background paint issues with Task manager/B'Manager in maximized mode
  • Issue 8587: Regression: Encoding auto-detect doesn't work any more
  • Issue 8517: tabbing should work on a SSL interstitial page
The detailed list of all revisions is also available.

Find about the Dev channel and how to subscribe at http://dev.chromium.org/getting-involved/dev-channel.

Please report bugs at http://code.google.com/p/chromium/issues/list.

Jonathan Conradt
Engineering Program Manager
URL: http://googlechromereleases.blogspot.com/2009/03/dev-channel-update-201710.html

Tuesday, March 24, 2009

[Gd] Netlog's first Developer Day - April 2, 2009 at Kinepolis in Brussels (Belgium)

| More

OpenSocial API Blog: Netlog's first Developer Day - April 2, 2009 at Kinepolis in Brussels (Belgium)

Netlog is a fun community counting more than 40 million members all over the world. With more than 60% of our users between the ages of 14 and 24, we can also say that Netlog is the favourite place for many youths to meet online. We joined the OpenSocial initiative at the beginning of 2008, and since that time we have been improving our platform for users and developers alike. After more than a year on OpenSocial we have many stories to share.

If you'd like to learn from our team and from other developers who have been building great applications for Netlog users, here is an open invitation for you: on April 2nd we will be hosting our first Developer Day at Kinepolis in Brussels, Belgium. This is a one-day, free admission event.

We'll dedicate the morning to sharing information about our APIs, gaming platform, localization technology and monetization possibilities, and will also offer you a codelab in the afternoon.

Mark your calendar and start spreading the word! Email us at netlogday@netlog.com if you have any questions.

We'll be thrilled to have you join us. For more info, check out our blog post.

For more information about Netlog’s OpenSocial implementation go to http://en.netlog.com/go/developer/opensocial.

Posted by Folke Lemaitre, VP Engineering, Netlog
URL: http://blog.opensocial.org/2009/03/netlogs-first-developer-day-april-2.html

[Gd] Toward an open web standard for 3D graphics

| More

Google Code Blog: Toward an open web standard for 3D graphics

For years, developers have tried to create rich 3D experiences on the web. However, the lack of a common way to render 3D graphics in the browser has forced them to use workarounds like special purpose plugins or software rendering frameworks. As a result, web users have generally experienced lower quality graphics compared to what can be found in today's desktop apps.

This is why Google is excited about the "Accelerated 3D graphics for the web" initiative by the Khronos Group and the Mozilla Foundation. As Javascript is becoming faster every day, we believe that it is time to create a general purpose API for 3D graphics on the web to allow developers to create compelling 3D applications in the browser. Khronos's initiative to develop a new, open web standard for high performance 3D graphics is a promising step in that direction. Google plans to contribute technology and web development expertise to the discussion within Khronos and the broader development community. As an active contributor to Khronos, Google would also like to encourage other technology companies to join Khronos in this effort and embrace a project that promises to move the web forward.

By Matthew Papakipos, Engineering Director and Vangelis Kokkevis, Software Engineer
URL: http://google-code-updates.blogspot.com/2009/03/toward-open-web-standard-for-3d.html

Monday, March 23, 2009

[Gd] Stable update: Fix default browser on Vista

| More

Google Chrome Releases: Stable update: Fix default browser on Vista

Google Chrome 1.0.154.53 has been released to the Stable channel. This is a minor bugfix release that addresses:
  • Issues 6504, 6732,  and 7568: Problems setting Google Chrome as the default browser on Windows Vista.
  • Issue 5806: Blank entries can appear in the address bar's list of suggestions.
  • Adding DigiNotar and SwissSign Gold as trusted certificate authorities for extended validation (EV) SSL certifciates.
See the release notes for additional changes.


--Mark Larson,
Google Chrome Program Manager
URL: http://googlechromereleases.blogspot.com/2009/03/stable-update-fix-default-browser-on.html