firecrawl/apps/test-suite/load-test.yml

77 lines
1.9 KiB
YAML
Raw Normal View History

2024-05-18 05:32:44 +08:00
config:
target: "https://staging-firecrawl-scraper-js.fly.dev/v0"
2024-05-22 20:30:32 +08:00
http:
timeout: 30
2024-05-18 05:32:44 +08:00
phases:
2024-05-24 03:36:05 +08:00
# /scrape
# - duration: 60
# arrivalRate: 10 # Initial load
# - duration: 120
# arrivalRate: 20 # Increased load
# - duration: 180
# arrivalRate: 30 # Peak load
# - duration: 60
# arrivalRate: 10 # Cool down
# /crawl
2024-05-23 05:20:24 +08:00
- duration: 60
arrivalRate: 1 # Initial load
- duration: 120
arrivalRate: 2 # Increased load
- duration: 180
arrivalRate: 3 # Peak load
- duration: 60
arrivalRate: 1 # Cool down
2024-05-18 05:32:44 +08:00
defaults:
headers:
2024-05-23 05:20:24 +08:00
Authorization: "Bearer YOUR_API_KEY"
2024-05-18 05:32:44 +08:00
scenarios:
2024-05-23 01:26:29 +08:00
# - name: Scrape a URL
2024-05-18 05:32:44 +08:00
# flow:
# - post:
2024-05-23 01:26:29 +08:00
# url: "/scrape"
2024-05-18 05:32:44 +08:00
# json:
2024-05-23 01:26:29 +08:00
# url: "https://www.scrapethissite.com"
2024-05-18 05:32:44 +08:00
# pageOptions:
# onlyMainContent: true
# capture:
2024-05-23 01:26:29 +08:00
# - json: "$.data.markdown"
# as: markdown_content
- name: Crawl a URL
flow:
- post:
url: "/crawl"
json:
2024-05-23 05:20:24 +08:00
url: "https://rsseau.fr"
2024-05-23 01:26:29 +08:00
crawlerOptions:
limit: 100
pageOptions:
onlyMainContent: true
capture:
- json: "$.jobId"
as: job_id
- think: 10
- get:
url: "/crawl/status/{{ job_id }}"
capture:
- json: "$.status"
as: crawl_status
until:
- condition: "equals"
value: "completed"
variable: "crawl_status"
retry:
count: 20
wait: 10
2024-05-18 05:32:44 +08:00
# - name: Search for a query
# flow:
# - post:
# url: "/search"
# json:
# query: "firecrawl"
# pageOptions:
# fetchPageContent: true
# capture:
# - json: "$.data[0].markdown"
# as: search_markdown_content