mobile project with openshift - ios

I would like to develop a mobile app which publish pictures online inside a mongodb on openshift.com.
At the same time I would like to host website where some customers can see a "wall" with all the publications.
My question is: Openshift.com is a good choice when you need to store datas (pictures, text) from smartphones and in the same time to host a website?
p.s. the pictures will be stored directly in the mongodb, is it a good way to do?
Thank you in advance

Yes, you would be best off writing a simple API that your mobile application will connect to (in your language of choice) to get the data into mongo. I personally would either store the images on the filesystem in your app-root/data directory, or store them on Amazon S3.

Related

Develop an iPhone GPS time based POI app?

I'd like to create an app that provides "time based" POI landmark markers on a typical map interface. For example, between the hours of 4:00pm-7:00pm display a bar that advertises their happy hour through the app.
Is the best way to handle this via a private database? Can I seed my records from other APIs that provide POI? Like Museums, libraries, etc? Perhaps use their POI records with my pivate time-based records?
I am a java PC app developer and have no experience with the iPhone. Where should I look to get started?
Use NodeJS, Express and MongoDB on a server, implement a web site which allows shops to register their location, time, and specials which are stored in the MongoDB.
Implement a JSON Restful service to pull the MongoDB data records for a remote mobile application.
Create a mobile web app using JQuery Mobile which uses the API and Google maps to present the data. Use HTML5 and javascript so that you mobile app works on all smart devices without the need of any market.
My first pass on the idea. But know that this is in the domain of big guys like Google, they will be doing this if they don't already have it covered.

Storing images not as part of app

I am building my new site and have a small group of images I want to display on the site.
They are not images to do with styling so it feels wrong to store them within the app/assets directory
I don't wish to put them on my Flickr account which builds by apps gallery as they are not that type of image.
I currently have them stored on an Amazon S3 bucket and link to them from there.
is there a better way. What way would you guys choose?
If I am already using the best way, is it worth linking to them using the standard url Amazon provides me with or should I direct one of my URL's to that point?
Your choice for Amazon S3 seems fine to me, and no, you should not change the standard URL's Amazon provides you with. Advantage is that your own web server is not bothered by the image URL's anymore!
I have a similar website storing "dynamic" pictures, and I keep them on cloudinary, which is a similar site. Your source directory should not in general store these "dynamic" pictures. They only consume disk space, and sites like Amazon S3 and Cloudinary are made just for that!

Is hosting JSON files used by my iphone app on 3rd party servers a good idea?

Here's the thing, I'm thinking of adding some "self-updating" properties to my app, which will enable the app to update it's contents every month. My current website was built using squarespace, which doesn't support file hosting. I really don't want to shell out money for another domain just for the sake of a monthly JSON file.
Are there any 3rd party providers that have this service? Such that all I need to do is upload my JSON file and get my URL? Is this a good idea?
Any help welcome.
Thanks.
Why don't you use a free service like StackMob to build your database online? This way you can update the data whenever you want. You might even build an app or a script to update the data easily and automatically.

What are the different ways to have communication between an iOS app and a database server?

I just starting to play around with iOS and web services. I'm writing a test app (My Books Collection) where a user should be able to register, login and then add books (Name, Author, Price, Edition, etc) and all the data should be stored in a database server. What options do I have to achieve this functionality?
I have programming experience but I'm very new to iOS and web services. Thank you!
Best practice is to have a web application mediator. We use php to handle queries from ios app and manages db. We use a light weight xml for ios - php communication and also add encryption sometimes. You can also add data compression to keep data usage low.

Storing images for multiple web sites

I've got two web sites (written in c#) which are pretty common:
One is an admin site (cms) where you add images into content as needed, through editor pages.
Second is the site where the content with images is shown.
Images should be stored outside these two sites but where and how?
You could store them on a third site for static content, then both sites would link to that content. That can give you some benefits if you really need scalability as well.
However, you may also store it in a shared database, or just a shared file share, that you have encapsulated logic that each sites that needs access to them uses.
If you dont want to both with the storage there are many "cloud" storage servers that will host all your images for you. (like Amazon S3, Smugmug, flickr).
But then you will have to build the logic in your app to upload the submitted images to your 3rd party storage provider.
You can store images inside a database. There are plenty of tutorials on how to store images in a database (images in mysql php, images in mysql asp.net, etc). The language isn't important, any of the tutorials can help show how to store images inside the database itself. Then it's just a matter of language specific calling the image out to display it.
Have you considered storing your images on something like Amazon S3? You could then access the images from both sites. Somehow, though, you'll need to store the URLs to the images and make them available for both sites.
If both sites run off of the same database, this is fairly easy, however, if they are separate databases, then I would suggest creating some sort of API on the creation site so that the content site can easily discover which images are available to be shown.

Resources