Message Boards Message Boards

1
|
10188 Views
|
3 Replies
|
3 Total Likes
View groups...
Share
Share this post:

Drawing down Cloud Credits with a static page deployment

If I create a new notebook in the WPC with one cell

$CloudCreditsAvailable

I can evaluate that cell until my heart's content and it does not change. Then, if I deploy it as a static published page, opening that page once, and returning to the WPC interface, evaluating the cell will cause my cloud credits to decrease. I can go to the dashboard and make the deployment of this page inactive, at which point I can no longer use the URL to open the static published page; however evaluating the cell in the WPC interface still draws down credits. Only when I close the WPC interface and reopen the notebook (I do not have to actually log out) am I able to evaluate the cell without it affecting my cloud credit balance.

The immediate question is: is this expected/anticipated behavior? Is there a reason why publishing a page that I'm currently editing result in credit draw down?

The bigger issue I have is how cloud credit use is applied. I am very hesitant to move from using the CDF plugin for deployments because I can't forecast the amount of credits a deployment is going to utilize. Any ideas or insights would be welcome.

POSTED BY: BoB LeSuer
3 Replies

Thanks for letting us know, we will look into this.

POSTED BY: EDITORIAL BOARD

Bob,
two objects evaluated in the desktop frontend create objects in the cloud:

obj1 = CloudDeploy[APIFunction[{}, DateList[] &]]

obj2 = CloudDeploy[
  Manipulate[
   ContourPlot3D[
    x^2 + y^2 + a z^3 == 1, {x, -2, 2}, {y, -2, 2}, {z, -2, 2}, 
    Mesh -> None], {a, -2, 2}]]

Click on every resulting link once ,wait and don's pull the slider in the contourplot. Now check the Calls and credits used:

In[9]:= CloudLoggingData[CloudObject[obj1]]["TotalCalls"]

Out[9]= <|"LastHour" -> 1, "LastDay" -> 1, "LastWeek" -> 1, 
 "LastMonth" -> 1, "LastYear" -> 1, "All" -> 1|>

In[10]:= CloudLoggingData[CloudObject[obj1]]["TotalCreditsUsed"]

Out[10]= <|"LastHour" -> 1, "LastDay" -> 1, "LastWeek" -> 1, 
 "LastMonth" -> 1, "LastYear" -> 1, "All" -> 1|>

In[11]:= CloudLoggingData[CloudObject[obj2]]["TotalCalls"]

Out[11]= <|"LastHour" -> 13, "LastDay" -> 13, "LastWeek" -> 13, 
 "LastMonth" -> 13, "LastYear" -> 13, "All" -> 13|>

In[12]:= CloudLoggingData[CloudObject[obj2]]["TotalCreditsUsed"]

Out[12]= <|"LastHour" -> 15, "LastDay" -> 15, "LastWeek" -> 15, 
 "LastMonth" -> 15, "LastYear" -> 15, "All" -> 15|>

Deploying a object from the desktop does not use credits. Calling a object from the wolfram server involves the cloud kernel and uses up credits. One click on obj2 results in 13 calls. Now move the slider a few times from left to right. The kernel is involved .. its not only your browser doing the work... hope this helps!

Thanks for the example, Pieter,

My issue is not so much with the desktop front end but the WPC front end, which looks like it does not know when a notebook has been unpublished. The "pseudo"-behavior is something like this:

  • Perform activity in WPC front end that does not consume credits
  • Publish that notebook, the published version of the notebook consumes credits
  • Activity in the WPC front end now consumes credits, even though it didn't prior to publishing the page

It's the third bullet point that I don't quite understand.

POSTED BY: BoB LeSuer
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract