I'm currently working on a project where I'll be tracking daily data for around 30 fictive companies. Every company has a name, rank and balance. I want to track the rank and balance by saving the data everyday.
Now my question is how to store this data, should I use csv files, Json files, or a database? And if thats the case, wat database should I use as a beginner?
My project is build in javascript with nodejs and discordjs.
You can add timestamps in json, you should take a look at it!
Since you're using discordjs, If I am not wrong you would be fetching details using the discord api. So for data storage you can go for firebase either Realtime database or firestore database. It's super easy to implement and easily scalable and there are too lot of additional feature you will get along. This way your database will be easily fetchable from anywhere also.
Also you can anytime download your database into csv. Here is the the official firebase node-js sdk documentation.
Related
I am currently building a serverless solution and run into a corner, basically i have a table and i want to be able to read data from that table in real-time as new entities are saved in the table from my client(front end react application). I have come across multiple solutions during research and i still am not sure which is best for my use case. I saw dynamodb streams allows you to get data as its being placed in the table, but i am still unsure as to how i can plug this in to my frontend to read the data, i also saw kinesis streams, and web socket api, the web socket api. im confused as to which to use.
My use case:
i have an orders table, where users place orders and i want when a user places an order to my order table, my front end(react) should be able to pick up that data and display it.
Can any aws devs direct me to a service that will be best to implement this usecase?
you can use Appsync Subscription, whenever a new order in your dynamoDb table Subscription will show it.
I want to host mongodb database remotely and access the database via querying it and display the results on web page.I came to know that mongodb atlas can be used for hosting it and in order to query the database crest is an API which can be used.But please help me ,whether crest is the thing which will satisfy the requirement that i want to achieve ?If yes then how to proceed with it.
Thanks.
I am currently using Atlas on a personal project and I must say that I am very pleased with it. It's good because you can try it for free and if your project starts to scale you can easily set it up according to your needs. You can also check Azure and AWS options. Regarding the question about Crest: if you need simple logic on your API, you can go for it. But if you want a more complex logic, I would recommend using express and mongojs or mongoose.
Im coding a static page app using Angular, which shows various Instagram and Twitter posts of the company, and shows the details of the members. I have few questions regarding this, and would like any help.
Firstly, I have about 100+ contacts to display on the first page. Should I create a Json by myself and retrieve it from the service, or should I create a backend and save it there ? I do not have any backend as of now.
Other thing, I was able to retrieve Instagram Json with media content using their API, the doubt im facing is, once I have the call done, will the Json change automatically when the user adds/edits their posts? Or will the Json be the same as I first called it with? Any help is appreciated. Thanks.
For your case, as you have fewer data using Firebase is the best approach. If you write a backend and maintaining it would cost you more. You can use Firebase service URL to retire those records. In future, if you want to add more data it would be easy.My suggestion is Firebase.
Should I create a Json by myself and retrieve it from the service, or should I create a backend and save it there ?
Are you revealing credentials or other sensitive information in the client? That would be one reason to have a backend apart from Instagram or Twitter. Do you envision exhausting API rate limits of Instagram or Twitter APIs? That would be another reason; you could cache results in your backend to reduce external API traffic. Do you need to process (reduce? translate?) the data before it gets to the client, or are you satisfied with performing any processing on the client (e.g. is it fast enough)?
TL;DR: It depends a lot on your particular requirements.
If you do want a backend, the recommendation in the answer from #praneeth-reddy to use Firebase is excellent. If you only need processing/transformation but no caching or separate storage, then AWS Lambda may also be worth considering. If you need more control (build vs. buy), you could write your own backend.
...will the Json change automatically when the user adds/edits their posts? Or will the Json be the same as I first called it with?
Angular can help you update content automatically if the client side data (think browser JavaScript memory) changes via its automatic change detection functionality, but you would have to provide your own logic (e.g. in Angular services perhaps leveraging RxJS) to update the client side data based on data from the APIs. You could poll to update periodically, or for better performance listen for changes using an asynchronous event/push mechanism such as websockets or streams.
I would like to create a separate firebase db for every client inside my firebase account. I don't want the client data to be a sub-branch of one single database. How do I achieve this without using the dashboard UI from firebase? I need to do it programmatically because there are many steps involved, e.g.:
Creation of an client administrator user
Creation of a predefined client database structure
Creation of a license for the client
Store information about the new client inside my license database (separate firebase db)
Creating separate backup script for every single client db
How do I set or get the secret of the new created database via API (programmatically)?
Any help is appreciated
As Kato answered on your related Github question:
There is no programmatic way to create a project. There is also a limit on the number of free projects you can create.
It is possible to create firebase projects, databases, apps using firebase tools.
Please refer to
firebase tools and documentation
I want to do an app with ionic framework and cordova for Android and iOs and I want to optimize at most the requests to the server.
I need to get data from php server (API) and store in the mobile phone, this data is related, so I think that a SQLite is the best option to store it in the device because of to show it is more fast to do a complex SQL than get a JSON stored in localstorage (for example) and search and link the data in the mobile. I'm right?
I need to do this and can do a Pull to refresh in the app and get only new data.
I've been watching some solutions but I don't know what is the best.
Parse/Firebase: This is difficult to administrate for non-specialists, for this I have a backend to enter and modify data with the relations easily. In addition this services return a JSON with more data that I need.
Persistence.js and Persistence.sync.js this works with mysql-server and sqlite-local but can I sync only one table or get only the new data? And I did't find a solution for php server.
CouchDB and PouchDB: I don't know if this can be sync only for a new records.
Receive data in JSON and store it in SQLite: I need to create functions to do this easier.
Any other solutions?
I'm very lost in this topic.
Thanks!!
CouchDB and PouchDB: I don't know if this can be sync only for a new records.
That’s the default. Plus they handle all the nasty sync details for you. Would highly recommend looking into this.