jeremy
jeremy
Explore posts from servers
RRailway
Created by jeremy on 7/23/2024 in #✋|help
Crashed service still working
Hi, I received an email telling me my service crashed. When I go to the dashboard the deployment said it's crashed, however, everything is alright, and the api is serving requests succesfully. I would expect it recovered/restarted itself, but the deployment is still marked as crashed somehow? 34849d22-d685-4e73-8858-fbd4fe42ea65
16 replies
RRailway
Created by jeremy on 7/22/2024 in #✋|help
Supported architectures
Is there any plans for Railway to support arm64?
3 replies
RRailway
Created by jeremy on 7/17/2024 in #✋|help
Database unreachable after getting "Client network socket disconnected"
Hey there, I created a temporary libSQL database to test out some upcoming migration I will need to run on production. I deployed the database using Brody's template https://railway.app/template/p121Tx The migration runs a schema migration first (step 1), successfully, a data migration (step 2), moving data from firebase to libsql, successfully and lastly a migration to move images around in Cloudflare R2 (step 3), which fails. In the last migration; I'm getting all the data migrated from step 2 in order to do some operation with R2. I have about ~45000 rows to go through, which I need to update back to the database using the libsql client. When trying to run an libsql.execute statement I'm getting the following error:
FetchError: request to https://URL.up.railway.app/v2/pipeline failed, reason: Client network socket disconnected before secure TLS connection was established
FetchError: request to https://URL.up.railway.app/v2/pipeline failed, reason: Client network socket disconnected before secure TLS connection was established
After getting this error, my database becomes unaccessible for some time. In general, it takes about 1/2 hours before I can connect to it again. I'm using TablePlus to connect to it, and it just stays stuck in the "Connecting to database..." until it fails. Even after trying to redeploy the database, it's still unreachable. I don't have any errors in the database logs either. Service has V2 runtime and beta edge proxy enabled. 34849d22-d685-4e73-8858-fbd4fe42ea65
7 replies
RRailway
Created by jeremy on 7/13/2024 in #✋|help
High usages with new builder
No description
12 replies
RRailway
Created by jeremy on 6/8/2024 in #✋|help
Runtime V2 not showing logs
No description
16 replies
PPrisma
Created by jeremy on 6/1/2024 in #help-and-questions
Raw SQL generated for cursor using libsql issue
To start with I am using:
"@libsql/client": "0.6.1",
"@prisma/adapter-libsql": "5.14.0",
"@prisma/client": "5.14.0",
"prisma": "5.14.0",
"@libsql/client": "0.6.1",
"@prisma/adapter-libsql": "5.14.0",
"@prisma/client": "5.14.0",
"prisma": "5.14.0",
I am handling a cursor-based pagination. My code looks like this:
const take = constants.pagination.limit + 1;
const cursor = input.after ? { id: decodeCursor(input.after) } : undefined;
const skip = input.after ? 1 : 0;

const data = await this.prismaService.user.findMany({
take,
cursor,
skip,
orderBy: {
createdAt: 'desc',
},
select: {
id: true,
}
})
const take = constants.pagination.limit + 1;
const cursor = input.after ? { id: decodeCursor(input.after) } : undefined;
const skip = input.after ? 1 : 0;

const data = await this.prismaService.user.findMany({
take,
cursor,
skip,
orderBy: {
createdAt: 'desc',
},
select: {
id: true,
}
})
When fetching the first batch of items, with after argument being null, I'm successfully getting the data. The raw generated SQL looks like this:
SELECT `main`.`User`.`id` FROM `main`.`User` ORDER BY `main`.`User`.`createdAt` DESC LIMIT 6 OFFSET 0
SELECT `main`.`User`.`id` FROM `main`.`User` ORDER BY `main`.`User`.`createdAt` DESC LIMIT 6 OFFSET 0
However, when trying to get the next batch based on the cursor, I'm getting an error from libSQL RESPONSE_TOO_LARGE: Response is too large. When looking at the generated SQL it looks like this:
SELECT `main`.`User`.`id` FROM `main`.`User` AND `main`.`User`.`createdAt` <= (SELECT `main`.`User`.`createdAt` FROM `main`.`User` WHERE (`main`.`User`.`id`) = (6))) ORDER BY `main`.`User`.`createdAt` DESC LIMIT -1 OFFSET 0
SELECT `main`.`User`.`id` FROM `main`.`User` AND `main`.`User`.`createdAt` <= (SELECT `main`.`User`.`createdAt` FROM `main`.`User` WHERE (`main`.`User`.`id`) = (6))) ORDER BY `main`.`User`.`createdAt` DESC LIMIT -1 OFFSET 0
I believe the -1 is a bug and the proper limit is not being applied correctly here. Does anyone have a pointer on how I can debug this locally and maybe local patch it?
4 replies
RRailway
Created by jeremy on 5/30/2024 in #✋|help
Service group just broke
Is there any updates that happened today or yesterday around service group? I was clicking on some of my service, and they started overlapping each of other (part of the same service group) and suddenly the service group disappeared. Looks like I will have to re-create all my services group. I had this error in console https://react.dev/errors/418?invariant=418 I am using Arc Is it still localStorage only or there is a plan to save the service groups settings more permanently? EDIT: well, it does seem like it's not localStorage anymore, so somehow, some of my groups disapeared and I had to re-create them 34849d22-d685-4e73-8858-fbd4fe42ea65
9 replies
RRailway
Created by jeremy on 5/2/2024 in #✋|help
Issue with the environment deploy changes flow
Step 1: I created a new variable in Shared Variables > my env Step 2: I pressed "apply to services" or whatever exact message was showing in the small tooltip in the bottom right of the screen Step 3: Added another variable manually on 2 other services Step 4: Changes the details of the changes. Everything looked good Step 5: Deploy the changes and my services are crashing Step 6: Check in each service, and when checking the shared variable I just added before, it shows as "<empty string>" Step 7: When going back to Shared variables > my env; the one I created just before is not there anymore Project id: 34849d22-d685-4e73-8858-fbd4fe42ea65 Browser: Arc
7 replies
CDCloudflare Developers
Created by jeremy on 4/24/2024 in #workers-help
Subrequests metrics
Hi there, I wrote a workers to cache request from my graphql endpoint. I mostly following the example here https://blog.cloudflare.com/introducing-the-workers-cache-api-giving-you-control-over-how-your-content-is-cached As a result I correctly get cached request from the Cloudflare Cache API with status "cf-cache-status: HIT". However, if I go to the analytics dashboard to "Workers (per zone) > Subrequests > Cached requests" it says 0. "Total requests" is correctly populated with the request I made. I'm looking at the documentation here https://developers.cloudflare.com/workers/observability/metrics-and-analytics/#subrequests and the way I'm doing it should be correct. Any pointers on why it's not showing any requests cached?
12 replies
RRailway
Created by jeremy on 1/31/2024 in #✋|help
Incorrect copy for Usage Limit Alert email
No description
15 replies
RRailway
Created by jeremy on 10/21/2023 in #✋|help
Removed my deployment, but still seeing metrics coming in
No description
6 replies
RRailway
Created by jeremy on 10/17/2023 in #✋|help
Math doesn't add up for service cost
No description
9 replies
RRailway
Created by jeremy on 9/24/2023 in #✋|help
How to specify a fixed version for a nix package
Is there a way to specify a fixed version for nixPkgs? something like this: nixPkgs = ["...", "zlib", "cdo@2.1.1"] At the moment I downgraded nixpacks altogether with nixpacksVersion but not ideal
24 replies
RRailway
Created by jeremy on 9/12/2023 in #✋|help
Inactive deployment stuck in "waiting"
No description
6 replies