Chat application in Rhomobile with asp.net server - xmpp

I want to integrate a chatapplication in an existing app in Rhomobile (ruby) and my server is a RESTful asp.net mvc server. I didn't find much useful information on how it's done using Rhomobile.
I already did some research and found that many people use xmpp/jabber.
But i don't realy know how to start and how to notify the user when there's a message waiting (if the user is not on the 'chatpage').
I can do polling, but that requires an open connection for every user and i worry about the battery of the mobile device.
Some questions:
What to use with a ruby client and an asp.net mvc sever?
Should i save the chatdata in the database on the central server since asp.net mvc is stateless?
If anyone knows a good guide or tutorial to help me through this, it would be nice - i'm a nembie on this
Thanks!

This is what RhoMobile have on their site.
http://docs.rhomobile.com/rhodes/connect-to-web-services
I also presume you can use whatever ruby and JavaScript/Jquery code you want.

Related

Implementation API for mobile APP

I am programming a Symfony2 App. The structure of my Symfony2 app like:
Login (username / password)
Get Survey for this Login / for this User
User input / click answers. After each click a Ajax request save the answer
User submit survey after answering every question
I have no experience with mobile apps like IOS, Android or Windows. The mobile will created by an other team. The question ist quite common, but which steps i must realize? Are there any literature that you can recommend me?
What was the right way to create an API?
How far Symfony2 supports to create an API for this use cases?
Unfortunately I have no experience on REST, but i suspect this is necessary, right?
I look forward to each answer.
Let me state the obvious first, if you start building a project with technologies you don't know enough about, it WILL be a nightmare. So by all means take your time to learn what you need.
REST is the reccomended standard to build an API since it's native http native and it's quite simple and flexible at the same time. There are tons of simple tutorials on REST, starting from Wikipedia, so I won't link them here.
But I'll tell you a secret, a web service can simply be any web page that reply to your requests with structured data. I.e. even a non-REST series of "webpages" the reply with JSON data can be defined a web service.
By now you see that you can easily do that with Symfony. If you already know how to do stuff and show pages with Symfony, only add JSONResponse to the mix , and also the _format routing parameter, and you should be on a good way.
You just create a path (i.e. an action) for whatever the mobile application needs to do. Of course later on you will learn the beauty of REST and refactor your API accordingly, but first thing you build a working system.
Reading this blog post is a good start. Now if your application will only serve API responses there is the very good Symfony REST Edition which already includes all bundles and tools needed to create an API centric application with Symfony2.
You also have the Lionframe framework but I didn't tested it yet.

Ado.NET "Disconnected Architecture" for web development

I am new to asp.net and ado.net. I must to develop a content management system with .net and I wonder which option is right for me, disconnected or connected architecture for web?
I dont understand why I should use dataset on online applications.
It sounds like you are getting started with ASP.NET so depending on which technology you prefer (MVC or Web Forms) either of these two tutorials provided by Microsoft will be of great help on general data access.
MVC: http://www.asp.net/mvc/tutorials/getting-started-with-ef-using-mvc
Web Forms: http://www.asp.net/web-forms/tutorials/data-access

Is ASP.NET MVC a Good Fit for an Event Ticketing Site?

Good Afternoon,
I'm rebuilding an event ticketing site originally developed using ASP.NET 3.5 WebForms and am considering using ASP.NET MVC2 for the rebuilt solution. I like the idea of friendly URLs as the current site has very long query string URLs for each specified event. MVC2 also appeals from a separation of concerns point of view as well. The biggest unknown for me is will MVC2 handle calls to 3 separate web services (SOAP and REST) to get ticket availability? That is, does the controller functionality permit use of such web services? Finally, MVC3 is due to RTM in January. Am I better off waiting for MVC3, or can I start the project in MVC2 and port it later?
Thanks for all your advice and insight.
MVC can handle any HTTP request as ASP.NET forms does. Indeed you should consider to use WCF for handling SOAP queries. And yes, sure you can easely create REST API with MVC.
It is better to start now, with ASP.NET MVC 3 RC2. It is very stable and nice. This will minimize migration work. Welcome to MVC happy world!
The controller will let you run pretty much any code you want.
I just started using MVC in a big project and it's turning out well. We went with MVC 3 and it's been a little tricky living on the edge, but it seems to have a lot of nice improvements. I'm extremely happy to be using MVC instead of Web Forms. To me, it seems to flow smoothly instead of fighting with the way the web works.

iPhone/iPad apps with backend databases?

We're investigating the iPhone Enterprise Developer Program as a way to develop and distribute in-house apps. Since our backends are all Windows, SQL server and Oracle databases, we have to find out a way to make our data available for the coming in-house apps.
As far as I know that Core Data is mainly based on SQLite as persistent store. I am not sure if there are any APIs available in iPhone SDK for SQL server or Oracle database? Another possibility, or very attractive strategy, is to build our own web-based REST services as CRUD gateway to our databases.
Personally, I prefer to integrate in-house apps with our ASP.NET based web services. I am not sure if this is possible. Are there any examples or documentations about this strategy?
an interesting option is to expose your data from your server using asp.net OData then use this project to generate a client in objective-C to consume your OData service.
As far as I am aware there are no approved API's to access a server based database. The way we do it in our organisation is pretty much the way you are suggesting. In some instances we are using SOAP but typically we just use a custom JSON or XML web service to access the data.
With regards to ASP.NET are you talking about making native iPhone Apps with ASP.NET or getting a native iPhone App to talk to an ASP.NET web service? If its the first then have a look at monotouch (don't know much about it), if its the later then this shouldn't cause issues. Just use NSURLConnection and deal with the resource structure on the App (be it JSON or XML).
The added advantage of using a web service rather than a straight database connection is that you get encryption for free using https.
Hope that helps
There's a product called SUP (Sybase Unwired Platform), it provides a framework to handle access to databases but has the advantage that there doesn't need to be an online access all the time, it stores persistent data locally and then can sync up with the host database using messaging.

Windows Workflow Foundation in ASP.NET 3.5 Web Application - Best Approach

What is the best way to use Windows Workflow Foundation in ASP.NET 3.5 Web Application.
In my case there are several workflows(sequential) which includes numerous steps, user has the privilege to save and exit at any of these steps; the state must be persisted, possibly in SQL Server.
Exposing workflows as web service is good idea? I have very little idea about workflows and only tried out wf console applications.
Please guide me in right direction, also I would like to know is there any specific and established architecture to use wf in ASP.NET Web Apps. We have layered architecture for our web apps (BLL, DAL, Services etc) and I would like to know where we can incorporate workflows in current architecture.
Many thanks in advance.
Update: thank you Rubens Farias for helping me out in first place.
We are still unsure which approach will be the best.
Please provide any example frameworks or sample webapplication which use workflow
So far...
1. Is it good idea to use Page Flow Application Block
2. There are lots of changes in WF4, should I wait for that?
3. Or use WF as Rubes Farias suggested
Please guide me friends, am desperate :(
You definitely must read this document: Foundations: Workflow Services
You can to add an out-of-box persistence service, so your workflows get persisted into a SQL Server database, and to expose them as WCF services (RESTfull approaches is also available).