Storing images in file system, amazon-s3 datastores - image

There has been numerous discussions related to storing images (or binary data) in the database or file system (Refer: Storing Images in DB - Yea or Nay?)
We have decided to use the file system for storing images and relevant image specific metadata in the database itself in the short term and migrate to an amazon s3 based data store in the future. Note: the data store will be used to store user pictures, photos from group meetings ...
Are there any off the shelf java based open source frameworks which provide an abstraction to handle storage and retrieval via http for the above data stores. We wouldn't want to write any code related to admin tasks like backups, purging, maintenance.

Jets3t - http://jets3t.s3.amazonaws.com/index.html
We've used this and it works like a charm for S3.
I'm not sure I understand if you are looking for a framework that will work for both file-system storage and S3, but as unique as S3 is, I'm not sure that such a thing would exist. Obviously with S3, backups and maintenance are handled for you.

Related

SpringBoot: How to store image/video files when using on-prem

I have a spring boot application that receives data from user, the data contains images and videos.
I am a little skeptical about storing big files on database(MongoDb). As I can not use Amazon S3, what should I do to save images/videos ?
Should I save them in a folder in a docker on a VM? or
should I convert the image/video file to base64 and save it on MongoDb?
in case 1) is a good option, what should be my implementation approach? I am new to this,
i appreciate your comments.
I tried to save image/video files to database but it is extremely time consuming.

SurrealDB - store binary files

Is it possible to store binary files (e.g. images) using SurrealDB?
I can't find anything about this in docs.
If not, where can I store images since all the other data is stored in SurrealDB.
SurrealDB wasn't created as a file store. For this purpose, you can use for example object storage. Nearly every cloud service provide object storage.
If you want an open-source solution that can host on your own, you can check MinIO object storage - github repo.

How to display image from database with Laravel and react hooks

I am new in reactjs I want to display image with Laravel and react hooks any easy way and fast to load image from Laravel path.?
there’s a lot of way to handle display image :
store your file path to db, so you can call your image using path
store you image to db using blob type (but i don’t recommend this approach because it will make your db size increases significantly)
you can store your image to aws / another cloud services
From my experience, it’s better to store path only into the database then store image file in your system. because it have better performance than store the image to db. the disadvantage using this approach is while you have to backup the images and db. or if you move the image manually, the path in db will not match with the actual image’s path. it will throw an error.
you can try using aws since aws give a free tier s3 storage.
For further information about use s3 storage, you can read Laravel documentation about the Filesystem for the technical use.

Using Amazon S3 in place of an SFTP Server

I need to set up a repository where multiple people can go to drop off excel and csv files. I need a secure environment that has access control so customers logging on to drop off their own data can't see another customers data. So if person A logs on to drop a word document they can't see person B's excel sheet. I have an AWS account and would prefer to use S3 for this. I originally planned to setup an SFTP server on an EC2 server however, I feel that using S3 would be more scalable and safer after doing some research. However, I've never used S3 before nor have I seen it in a production environment. So my question really comes down to this does S3 provide a user interface that allows multiple people to drop files off similar to that of an FTP server? And can I create access control so people can't see other peoples data?
Here are the developer resources for S3
https://aws.amazon.com/developertools/Amazon-S3
Here are some pre-built widgets
http://codecanyon.net/search?utf8=%E2%9C%93&term=s3+bucket
Let us know your angle as we can provide other ideas knowing more about your requirements
Yes. It does, you can actually control access to your resources using IAM users and roles.
http://aws.amazon.com/iam/
You can allow privileges to parts of an S3 bucket say depending on the user or role for example:
mybucket/user1
mybucket/user2
mybucket/development
could all have different permissions.
Hope this helps.

Where to store images in Amazon AWS for use in RDS

I am currently creating a bunch of tables on the MySQL service in Amazon RDS. Several of the tables need to have image links in them. What I am trying to figure out, is where do I put the images? Do they go in RDS somewhere? or do i put them in S3 and link them to RDS? If the latter, how do I do that?
I have googled the heck out of this, with no conclusion so any assistance would be great.
Depending on the image sizes, use cases, etc, I would probably store the images in S3.
You can store the S3 path as a database field. You can create a bucket as a domain name (ie, images.example.com), and point the CNAME to the bucket to get direct access to the images. You can also use the various S3 libraries to generate a time limited signed URL if you want to include security.
You can either store them just as binary-data in a column in RDS or you can use S3. If you use S3 you store the http-url to the image in RDS and then get the image over http from S3.

Resources