Skip to content

Commit b2c8829

Browse files
committed
fix: a couple of small changes
1 parent 2991d54 commit b2c8829

File tree

8 files changed

+12
-17
lines changed

8 files changed

+12
-17
lines changed

sources/academy/platform/getting_started/actors.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ After the Actor has completed its run (you'll know this when you see **SEO audit
3737

3838
## The "Actors" tab {#actors-tab}
3939

40-
While still on the platform, click on the tab with the **< >** icon which says **Actors**. This tab is your one-stop-shop for seeing which Actors you've used recently, and which ones you've developed yourself. You will be frequently using this tab when developing and testing on the Apify platform.
40+
While still on the platform, click on the tab with the **&lt;/&gt;** icon which says **Actors**. This tab is your one-stop-shop for seeing which Actors you've used recently, and which ones you've developed yourself. You will be frequently using this tab when developing and testing on the Apify platform.
4141

4242
![The "Actors" tab on the Apify platform](./images/actors-tab.jpg)
4343

sources/academy/platform/getting_started/apify_client.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ print(items)
218218

219219
## Updating an Actor {#updating-actor}
220220

221-
If you check the **Settings** tab within your **adding-actor**, you'll notice that the default memory being allocated to the Actor is **2048 MB**. This is a bit overkill considering the fact that the Actor is only adding two numbers together - **256 MB** would be much more reasonable. Also, we can safely say that the run should never take more than 20 seconds (even this is a generous number) and that the default of 3600 seconds is also overkill.
221+
If you check the **Settings** tab within your **adding-actor**, you'll notice that the default timeout being set to the Actor is **360 seconds**. This is a bit overkill considering the fact that the Actor is only adding two numbers together - the run should never take more than 20 seconds (even this is a generous number). The default memory being allocated to the Actor is **256 MB**, which is reasonable for our purposes.
222222

223223
Let's change these two Actor settings via the Apify client using the [`actor.update()`](/api/client/js/reference/class/ActorClient#update) function. This function will call the **update Actor** endpoint, which can take `defaultRunOptions` as an input property. You can find the shape of the `defaultRunOptions` in the [API documentation](/api/v2/act-put). Perfect!
224224

sources/academy/platform/getting_started/creating_actors.md

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ You can create an Actor in several ways. You can create one from your own source
1515

1616
## Choose the source {#choose-the-source}
1717

18-
Once you're in Apify Console, go to [Development](https://console.apify.com/actors/development/my-actors), and click on the **Develop new** button in the top right-hand corner.
18+
Once you're in Apify Console, go to [Actors](https://console.apify.com/actors), and click on the **Develop new** button in the top right-hand corner.
1919

2020
![Develop an Actor button](./images/develop-new-actor.png)
2121

@@ -169,12 +169,6 @@ After the Actor finishes, you can preview or download the extracted data by clic
169169

170170
And that's it! You've just created your first Actor and extracted data from a website 🎉.
171171

172-
## Getting stuck? Check out the tips 💡 {#get-help-with-tips}
173-
174-
If you ever get stuck, you can always click on the **Tips** button in the top right corner of the page. It will show you a list of tips that are relevant to the Actor development.
175-
176-
![Tips](./images/actor-tips.png)
177-
178172
## Next up {#next}
179173

180174
We've created an Actor, but how can we give it more complex inputs and make it do stuff based on these inputs? This is exactly what we'll be discussing in the [next lesson](./inputs_outputs.md)'s activity.
106 KB
Loading
47.6 KB
Loading

sources/academy/platform/getting_started/inputs_outputs.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,23 +71,24 @@ Finally, **Save** and **Build** the Actor just as you did in the previous lesson
7171

7272
## Configuring an Actor with inputs {#configuring}
7373

74-
If you scroll down a bit, you'll find the **Developer console** located under the multifile editor. By default, after running a build, the **Last build** tab will be selected, where you can see all of the logs related to building the Actor. Inputs can be configured within the **Input** tab.
74+
By default, after running a build, the **Last build** tab will be selected, where you can see all of the logs related to building the Actor. Inputs can be configured within the **Input** tab.
7575

7676
![Configuring inputs](./images/configure-inputs.jpg)
7777

7878
Enter any two numbers you'd like, then press **Start**. The Actor's run should be completed almost immediately.
7979

8080
## View Actor results {#view-results}
8181

82-
Since we've pushed the result into the default dataset, it, and some info about it can be viewed by clicking this box, which will take you to the results tab:
82+
Since we've pushed the result into the default dataset, it, and some info about it, can be viewed in two places inside the Last Run tab:
8383

84-
![Result box](./images/result-box.png)
84+
1. **Export** button
85+
2. **Storage** &rarr; **Dataset** (scroll below the main view)
8586

8687
On the results tab, there are a whole lot of options for which format to view/download the data in. Keep the default of **JSON** selected, and click on **Preview**.
8788

8889
![Dataset preview](./images/dataset-preview.png)
8990

90-
There's our solution! Did it work for you as well? Now, we can download the data right from the results tab to be used elsewhere, or even programmatically retrieve it by using [Apify's API](/api/v2) (we'll be discussing how to do this in the next lesson).
91+
There's our solution! Did it work for you as well? Now, we can download the data right from the Dataset tab to be used elsewhere, or even programmatically retrieve it by using [Apify's API](/api/v2) (we'll be discussing how to do this in the next lesson).
9192

9293
It's important to note that the default dataset of the Actor, which we pushed our solution to, will be retained for 7 days. If we wanted the data to be retained for an indefinite period of time, we'd have to use a named dataset. For more information about named storages vs unnamed storages, read a bit about [data retention on the Apify platform](/platform/storage/usage#data-retention).
9394

sources/platform/actors/development/deployment/source_types.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ Remember that each key can only be used once per Git hosting service (GitHub, Bi
7373

7474
### Actor monorepos
7575

76-
To manage multiple Actors in a single repository, use the `dockerContextDix` property in the [Actor definition](/platform/actors/development/actor-definition/actor-json) to set the Docker context directory (if not provided then the repository root is used). In the Dockerfile, copy both the Actor's source and any shared code into the Docker image.
76+
To manage multiple Actors in a single repository, use the `dockerContextDir` property in the [Actor definition](/platform/actors/development/actor-definition/actor-json) to set the Docker context directory (if not provided then the repository root is used). In the Dockerfile, copy both the Actor's source and any shared code into the Docker image.
7777

7878
To enable sharing Dockerfiles between multiple Actors, the Actor build process passes the `ACTOR_PATH_IN_DOCKER_CONTEXT` build argument to the Docker build.
7979
It contains the relative path from `dockerContextDir` to the directory selected as the root of the Actor in the Apify Console (the "directory" part of the Actor's git URL).

sources/platform/actors/running/usage_and_resources.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ The Actor has hard disk space limited by twice the amount of memory. For example
5656

5757
## Requirements
5858

59-
Actors built with [Crawlee](https://crawlee.dev/) use autoscaling. This means that they will always run as efficiently as they can based on the allocated memory. If you double the allocated memory, the run should be twice as fast and consume the same amount of compute units (1 * 1 = 0.5 * 2).
59+
Actors built with [Crawlee](https://crawlee.dev/) use autoscaling. This means that they will always run as efficiently as they can based on the allocated memory. If you double the allocated memory, the run should be twice as fast and consume the same amount of [compute units](#what-is-a-compute-unit) (1 * 1 = 0.5 * 2).
6060

6161
A good middle ground is `4096MB`. If you need the results faster, increase the memory (bear in mind the [next point](#maximum-memory), though). You can also try decreasing it to lower the pressure on the target site.
6262

@@ -67,7 +67,7 @@ Autoscaling only applies to solutions that run multiple tasks (URLs) for at leas
6767
[//]: # (If you read that you can scrape 1000 pages of data for 1 CU and you want to scrape approximately 2 million of them monthly, that means you need 2000 CUs monthly and should [subscribe to the Business plan]&#40;https://console.apify.com/billing-new#/subscription&#41;.)
6868

6969

70-
If the Actor doesn't have this information, or you want to use your own solution, just run your solution like you want to use it long term. Let's say that you want to scrape the data **every hour for the whole month**. You set up a reasonable memory allocation like `4096MB`, and the whole run takes 15 minutes. That should consume 1 CU (4 \* 0.25 = 1). Now, you just need to multiply that by the number of hours in the day and by the number of days in the month, and you get an estimated usage of 720 (1 \* 24 \* 30) CUs monthly.
70+
If the Actor doesn't have this information, or you want to use your own solution, just run your solution like you want to use it long term. Let's say that you want to scrape the data **every hour for the whole month**. You set up a reasonable memory allocation like `4096MB`, and the whole run takes 15 minutes. That should consume 1 CU (4 \* 0.25 = 1). Now, you just need to multiply that by the number of hours in the day and by the number of days in the month, and you get an estimated usage of 720 (1 \* 24 \* 30) [compute units](#what-is-a-compute-unit) monthly.
7171

7272
:::tip Estimating usage
7373

@@ -99,7 +99,7 @@ It's possible to [use multiple threads in Node.js-based Actor](https://dev.to/re
9999

100100
When you run an Actor it generates platform usage that's charged to the user account. Platform usage comprises four main parts:
101101

102-
- **Compute units**: CPU and memory resources consumed by the Actor.
102+
- **[Compute units](#what-is-a-compute-unit)**: CPU and memory resources consumed by the Actor.
103103
- **Data transfer**: The amount of data transferred between the web, Apify platform, and other external systems.
104104
- **Proxy costs**: Residential or SERP proxy usage.
105105
- **Storage operations**: Read, write, and other operations performed on the Key-value store, Dataset, and Request queue.

0 commit comments

Comments
 (0)