https://discord.cloudflare.com logo
Join Discord
Powered by
# workers-discussions
  • j

    Just a Sniper fox

    02/16/2023, 4:09 PM
    Heyyo
  • j

    Just a Sniper fox

    02/16/2023, 4:09 PM
    I can't get Postgres working
  • j

    Just a Sniper fox

    02/16/2023, 4:09 PM
    Can someone help me? #1075506748460380310
  • e

    Edvard

    02/16/2023, 5:47 PM
    I cant seem to find much information regarding the limitations of websockets and worker 🤔 Sorry if i have missed something blatant, but does anyone know where i could find such info?
  • e

    Edvard

    02/16/2023, 5:53 PM
    Never mind! Just bad search engine results, so had to scroll for abit
  • s

    silentdevnull

    02/16/2023, 6:41 PM
    before I build this worker I want to see if anyone has a better idea on this with cloudflare. Right now I have a basic php page that a form post to build the url and then does a redirect to the built url. I was just going to convert the the form action to a worker but wanted to see maybe if there was a better way of doing it in CF without a worker.
  • e

    embed

    02/16/2023, 7:20 PM
    can you not do it client side?
  • e

    embed

    02/16/2023, 7:20 PM
    it sounds like a client side job unless you need to query the db for data or something
  • s

    silentdevnull

    02/16/2023, 7:22 PM
    I would think I should be able to do it client side. No query or anything just take the form action build a url and redirect over to them. Would you think I could do it in pages?
  • j

    jsoncx

    02/16/2023, 7:50 PM
    Hey folks, I'm hitting the 150char limit in workers logs for logpush. Is that a limit that can be raised?
  • s

    Skye

    02/16/2023, 7:51 PM
    Probably best to ask in #1041788765783474216 - that's where the team will look 🙂
  • j

    jsoncx

    02/16/2023, 7:51 PM
    Thanks!
  • d

    dave

    02/17/2023, 2:51 AM
    pretty sure the Worker logging route bug is not fixed 😦
  • d

    dave

    02/17/2023, 2:54 AM
    oh it started to log randomly agian
  • d

    dave

    02/17/2023, 3:26 AM
    well this is a super weird issue
  • d

    dave

    02/17/2023, 3:26 AM
    I cannot use POST on a wildcard subdomain
  • d

    dave

    02/17/2023, 3:26 AM
    defining the domain makes it work fine
  • d

    dave

    02/17/2023, 2:36 PM
    I get a 522 on the wildcard route when POSTing; known issue?
  • d

    dave

    02/17/2023, 3:13 PM
    Oh I figured it out I think..
  • d

    dave

    02/17/2023, 3:14 PM
    Was missing the /* at the end of the route.
  • d

    dave

    02/17/2023, 3:14 PM
    No clue why GETs were working.
  • n

    Noodles

    02/17/2023, 8:08 PM
    Hey all. Just another quick question. What is the best way to restrict a worker to only being used by another cloudflare pages site? I built an API on the worker where all but one endpoint needs to be restricted to only being used by a cloudflare pages project. The one other endpoint needs to be public. What would be the best way of going about this?
  • p

    Plotzes

    02/17/2023, 8:18 PM
    my first thought is that you should check if a request comes from cloudflare (either through ASN or IP address) and then you can safely check the
    CF-Worker
    header to see what worker is calling your API
  • p

    Plotzes

    02/17/2023, 8:18 PM
    i use this in one of my projects like this:
  • k

    korz

    02/17/2023, 8:30 PM
    Hey all - I built a small application to explore Cloudflares free tier (https://koryporter.com/posts/exploring-cloudflares-free-tier) and got some really useful feedback on my rate limiting solution using KV being a bad idea because of both the eventually consistent nature and the fact that the write limits are quite low. Durable objects would solve for this problem, but they aren’t on the free tier - anyone solved this before within the bounds of the free tier?
  • h

    HardAtWork

    02/17/2023, 8:31 PM
    Like this? https://blog.cloudflare.com/unmetered-ratelimiting/
  • k

    korz

    02/17/2023, 8:46 PM
    This should do the job, tyvm!
  • h

    HardAtWork

    02/17/2023, 9:01 PM
    Happy to help!
  • j

    jumpturn

    02/17/2023, 11:19 PM
    cannot access key in worker - startup says 'Your worker has access to the following bindings: - KV Namespaces: - FT: . but await FT.get("....") errors with FT is not defined. any tips?
  • j

    jumpturn

    02/17/2023, 11:20 PM
    oh - put an env in front of FT - docs out of date
1...227922802281...2509Latest