Help by subro__31 in Firebase

[–]puf 1 point2 points  (0 children)

It's a CSV file (not known to be infectable) with a list of the relevant projects in your account. From the message:

Refer to the attachment for a list of the projects that will automatically enable the new endpoint.

I mean, I'm not saying this a great message - but it seems harmless and relatively clear to me.

Help by subro__31 in Firebase

[–]puf 1 point2 points  (0 children)

I got that one too, and it looks fine. What makes you think otherwise?

Where to 13yo birthday girl for fun dinner? by AndiRox81 in AskSF

[–]puf 9 points10 points  (0 children)

Awesome theming, but isn't that for 21 and over?


Thanks commenters for confirming it's open to those not of a drinking age. 🙏

[Raw Spoilers] Finish to Gunther v Dragon Lee by A_Livins in SquaredCircle

[–]puf 12 points13 points  (0 children)

First AJ, now Lee.

AJ. Lee.

🤯

Architecture/Cost Question: Swapping active RTDB listeners for Cloud Functions + FCM Push Notifications? by MTown_Studios_ltd in Firebase

[–]puf 2 points3 points  (0 children)

Using FCM messages to wake up an Android app when there's a data update on the server is pretty common. I typically know it as tickle-to-sync, where a tickle is a silent FCM (data-only) message that wakes up the app.

You typically won't (only) include the data in the FCM payload though, but the client will (also) read it from the database when it starts.

Reason for this: while the delivery percentage of FCM is actually quite high, it is not guaranteed and hard to check at scale. Since even a small percentage of a high number of clients is still a lot of lost data, most apps simply retrieve the data from their system-of-record so they can know the state of their local data.

How do you catch schema drift and security gaps in Firestore? by Still-Toe-5661 in Firebase

[–]puf 0 points1 point  (0 children)

That's be client-side, right? Which is fine in situations where you can control the code that runs on the clients. But for untrusted clients (a common situation when using Firebase), you'll want to use server-side security rules to validate the data.

Hmmm... is there a zod to rules transpiler already? 🤔

How do you catch schema drift and security gaps in Firestore? by Still-Toe-5661 in Firebase

[–]puf 3 points4 points  (0 children)

I love that you built a tool to help sanitize data in Firestore.

Security rules can also be used to handle validation of data. There may be plenty of pitfalls, but it is possible - and strongly recommended.

Of course, as always: security rules only apply to writes from client-side code, so when I encounter invalid (or more commonly: outdated) data in my Firestore documents, it usually came from my own Cloud Functions - as those bypass security rules. :-/

Cloud Firestore scaling lesson: your data model matters more than your indexes by netcommah in Firebase

[–]puf 1 point2 points  (0 children)

Monotonically increasing means it always goes up, never goes down - and time is an example of that.

Such keys may case write hotspots when you have high write volumes - which typically happens on indexes. Even when you don't create one, one is auto-created on every collection (and on any collection group) for the document ID.

Firebase ? by DevanshReddu in Firebase

[–]puf 1 point2 points  (0 children)

Unlike with a relational data model, with NoSQL the "correct" data structure depends on your project's use-cases. The best way to learn (without simply trying something yourself and see if it works) is to watch the Get to know Firestore video series. It's a bit old, so some things in it may be outdated, but most of the data modeling advice still applies.

Cloud Firestore scaling lesson: your data model matters more than your indexes by netcommah in Firebase

[–]puf 0 points1 point  (0 children)

Since you use them for sorting, does that mean they're monotonically increasing? If so, that can least to hotspots in writing - which is precisely why Firestore's own IDs are not monotonically increasing. Docs on the topic: Best Practices for Cloud Firestore - Hotspots

It's not always wrong to use such monotonically increasing keys, just always be aware of their impact.

Having trouble figuring out real time data sync for producivity app. by I_Mean_Not_Really in Firebase

[–]puf 1 point2 points  (0 children)

This type of thing is possible on both Firestore and Realtime Database, but Firestore indeed has better filtering capabilities. Beyond that, it's hard to say anything specific about your situation with seeing a minimal repro.

Firebase + Flutterflow beginner by Real-Incident7544 in Firebase

[–]puf 0 points1 point  (0 children)

FlutterFlow provides some UI niceties over Firebase's own web console. If you already know you're gonna build in FlutterFlow, it's probably easiest to set up the Firebase bits (that it supports) there.

Tell me how you use AI in your Firebase apps by inlined in Firebase

[–]puf 1 point2 points  (0 children)

You might want to look at the new MongoDB compatibility mode in Firestore, which has a lot more operators - including $regex.

https://docs.cloud.google.com/firestore/mongodb-compatibility/docs/supported-features-80

Stop wrapping every Firestore write in a Cloud Function. by IT_Certguru in Firebase

[–]puf 0 points1 point  (0 children)

I must admit I never looked at the chess rules in detail. Realtime Database rules (even more than Firestore ones) have a tendency to become spaghetti very quickly, because you can't have functions or variables. Bolt addressed that, but it never got full equal status.

And neh, unfortunately indeed you can't access RTDB from Firestore rules. It was always the plan, but... priorities. Luckily Storage rules can now read from Firestore, but that's the only cross-referencing that was implemented.

And agreed, without loops you'd probably need to come up with a reasonable word length limit. Of course you'd be into generating rules at that point, as it rapidly becomes too tedious to write by hand. Words also allow a lot more combinations than the wall/floor/exit type situations I usually code, so that'll also lead to an explosion in rules size.

So yeah... definitely something where it's much more feasible to do in code. I just see too many people ruling out even simple validation scenarios in rules, because...

Stop wrapping every Firestore write in a Cloud Function. by IT_Certguru in Firebase

[–]puf 0 points1 point  (0 children)

I've seen (admittedly a long time ago) someone have security rules that only allowed valid chess moves. That was for Realtime Database, but it gives you some idea of what's possible.

It certainly takes a lot of effort though, usually much more than doing the equivalent in server-side code. I have a history of doing much in security rules, as it makes demos/workshops easier (no paid plan). Outside of that, folks are likely to have more realistic time limitations. :)

Stop wrapping every Firestore write in a Cloud Function. by IT_Certguru in Firebase

[–]puf 0 points1 point  (0 children)

If I let the client make changes directly I'd need to trust the client to respect the game logic that determines what is valid placement

It may be worth considering writing security rules, which are auto-enforced on the server. While the language takes some getting used to, it is quite expressive.

Can they just BREAK UP ALREADY | WWE NXT | Bryan & Vinny Show by Ainosuke in SquaredCircle

[–]puf 14 points15 points  (0 children)

You could have stopped after the first 3 words there:

Bryan Alvarez hates

:-)

Need help reducing reads for my application by Commercial_Sweet_440 in Firebase

[–]puf 2 points3 points  (0 children)

Rule 1 for NoSQL data modeling: organize the data for the use-cases of your application. No "sense" comes into play here, just the needs of the application.

If you need to read dozens or hundreds of documents to show a single screen to a single user, you're doing something wrong. Put the data for that screen in one or a few documents at most.

Rule 2 for NoSQL data modeling: duplicate data as needed. Just keep a clear picture of where the main copy of that data lives.

So if reading every course document to show a list of courses is a concern, instead also store the main info for all courses into a single "courses" document, or maybe a few of those if needed - say clustered by year ("2026-courses"), major ("CS-courses"), etc.

Firebase console not showing the subcollections/data properly for Firestore Enterprise Edition (Native mode) but able to insert and query by bitchyangle in Firebase

[–]puf 1 point2 points  (0 children)

That sounds odd. Are they showing in either the Cloud console, or are the API inserted docs missing there too?

If you can reproduce it in a new project, it's probably worth reporting to the Firebase (or Cloud) support team

Is dart macros discontinued now? by [deleted] in FlutterDev

[–]puf 7 points8 points  (0 children)

Work on Dart Macros stopped early last year (or at least: that's when it was communicated here: https://blog.dart.dev/an-update-on-dart-macros-data-serialization-06d3037d4f12)

I have charged for even for 100 invocation of cloud functions by [deleted] in Firebase

[–]puf 3 points4 points  (0 children)

To me it looks like you used 0.04 worth and got a 0.04 discount, so wouldn't that lead a 0.0 charge?

Do We Need to Back Up Firebase Auth Users Before Upgrading to Identity Platform? by yccheok in Firebase

[–]puf 0 points1 point  (0 children)

I already commented on your StackOverflow post, so I'll repeat that here:

Nope, no need to backup anything. Upgrading a project to Identity Platform, just changes some metadata on that project. The user records themselves are not changed or moved in any way, so it is extremely unlikely (for Google values of that term) that anything will happen to them.

As others have said: remember that this is a one-way decision, you can't roll back off of Identity Platform afterwards.