New answers tagged

0

Assuming that you're deserializing from the xml response and serializing from the objects themselves here is a model that may work for you. public abstract class FooMessage { [XmlIgnore] string A { get; set; } [XmlIgnore] string B { get; set; } [XmlIgnore] string C { get; set; } } public class UpdateFooRequest : ...


1

So what is really a resource, why it should be a mapping to one or more entities and what are some examples? When in doubt about anything relating to REST, consider the question in the context of the web. Here's a flow: I want to read Bob's homepage I know (probably because some other web page told me) that there is a http request handler with the id ...


1

A drag/drop UI typically encourages users to play around with the interface. You may not want to have every UI operation send data back to the server every time they interact with the interface. Depending on the specific interface it may not be an issue, but it's something to think about. What happens to the UI if the server response time starts to grow? How ...


0

One popular current 'state of the art' is to use a RESTful API service on the backend, and the front-end is responsible for data display and sending requests/commands to the server. This is usually done through simple HTTP requests to URLs with special meaning, but many other variants work generally the same way (with some varying details - think SOAP, etc). ...


2

If you value consistency then the service that stores the data should be the definitive 'master' source of what the data looks like. This means that the front end must defer to whatever the service says. Now that doesn't mean it cannot cache results, but it should not make assumptions about logic that may (or may not) be processed on the service. eg. Lets ...


1

First you need to decide how to make this change. Either update all the necessary invoice date fields or cancel the invoice and copy/rebuild all the data with a different date and possibly invoice number. Once you can code making this change, you can then decide on how to apply it to many invoices. If you think the problem is going to continue to stem from ...


1

In my programming environment (MacOS X / iOS) it is quite trivial - I create a semaphore, start the asynchronous request, the asynchronous request will unlock the semaphore when it's done, and then I lock the semaphore (which will wake up when the asynchronous request is done). Maybe six or eight lines of code. On the other hand, synchronous requests, ...


3

I think making clients wait for their web requests is not optimal. Even seconds are too much. A better way in my opinion is to immediately return the web request, run the asynchronous service and either make the client poll in regular intervals or much better setup a communication channel with the client in the form of websockets for example. Edit: Given ...


1

By discarding REST, you lose much more than just HATEOAS. If your microservices are public (and it's a good idea for them to be public or at least tend towards being public one day┬╣), using anything other than REST and SOAP would be problematic: Some developers never used AMQP, Some have used AMQP, but are often much more familiar with REST and SOAP, AMQP ...



Top 50 recent answers are included