Questions tagged [web-services]

Web services are software systems designed to support interoperable machine-to-machine interaction over a network.

Filter by
Sorted by
Tagged with
0 votes
1 answer
208 views

Is 10 KB a large amount of data to pass around each time a user makes an API call?

Each time a user of my APP / website interacts with the APP such that it makes an API call to the backend, the backend will make an API call to the mongoDB database to retrieve the document that holds ...
Bear Bile Farming is Torture's user avatar
-1 votes
1 answer
100 views

How are first-time users signup requests authenticated?

I have a web service. When a user makes a request, traefik first redirects it to my users micro service, to pass through an authentication function. The token (or username+password, on first request) ...
Juan Perez's user avatar
0 votes
2 answers
297 views

Is this service considered "an API"? Could it benefit from being Restful?

I'm confused about the meaning of API, specially in the context of REST. I'm thinking of one example. My company creates an application that runs on a server (the "backend"). (JavaScript in ...
Juan Perez's user avatar
1 vote
2 answers
133 views

Microservice Granularity: Should a service ever be broken into smaller services with a shared database?

I'm trying to understand the size of a micro service. Fake situation: Data is read 1,000,000 times for every write. So when you scale out you generally only care about scaling out for the 'GET' ...
nanotek's user avatar
  • 301
-1 votes
2 answers
285 views

How to deal with upsert PUT requests in a Spring Boot web application without crossing service and controller layers?

I've got a pretty simple web service that I need to add a PUT endpoint for that can handle upserts. This application is primarily a middleware layer to handle logging, caching and instrumentation in ...
Fulluphigh's user avatar
0 votes
0 answers
465 views

Dealing with third party api rate limit when using multiple services

I have 1 api key that has a rate limit 1000req/1min. I would like to somehow use 50% of that limit in service 1 and 50% of that limit in service 2. Let's say they're just 2 separate processes using ...
Konrad's user avatar
  • 1,559
0 votes
2 answers
113 views

Scheduled Task in webservice

The requirement is to trigger certain tasks (API calls) periodically for each user. But the frequency (time between triggers) is not fixed, the user can change it. In my existing solution I maintain a ...
shoaib30's user avatar
  • 101
-1 votes
2 answers
168 views

What are the benefits of HTTP statuses compared to custom JSON based protocol?

I am currently developing a service and a client and I use HTTP statuses for communicating certain info. For example, I have a POST /vikings endpoint that starts a long running process to create a ...
Anton Daneyko's user avatar
1 vote
3 answers
220 views

Is it OK for a public web service to use a database user with rights to execute DDL statements to access its underlying, exclusive database?

I wrote a Java web service using Spring that handles REST calls from the Internet. The web service uses a Postgres database underneath to store, modify and read data. The Postgres database is used ...
Harold L. Brown's user avatar
-1 votes
1 answer
75 views

How do I authenticate API request when I dont have credentials for the other end

I am developing an app in which I have to fetch data through company provided APIs. All the authentication is done on their end, so I don't have to build my own APIs. However, There are some ...
Prabhjot Singh's user avatar
1 vote
1 answer
2k views

How do you pass enums between microservices, without need to have copies of enums in different services?

I'm working with microservices, and I see an issue. There are two services, that transfer info between each other via jsons. Because of this, we have to store our enums in strings, and serialise-...
keldranase's user avatar
0 votes
2 answers
967 views

JWT logout: Sharing blacklisted invalid token among services

I am working on a microservices project involving 4 services - Auth Service, Service-A, Service-B and Service-C. All the services are implemented using Spring Boot. The Auth Service is responsible for ...
user14132461's user avatar
0 votes
1 answer
3k views

Blacklist JWT tokens or whitelist JWT tokens

I am working on a Spring Boot web application. The REST APIs are secured by JWT tokens. Currently I have only access token generated (not implemented refresh token concept). My question is related to ...
user14132461's user avatar
0 votes
2 answers
638 views

Does PUT need to be idempotent?

It has been said that "PUT is idempotent": The difference between PUT and POST is that PUT is idempotent: calling it once or several times successively has the same effect (that is no side ...
Mate Mrše's user avatar
0 votes
2 answers
80 views

What's the right way to handle authentication of users across 2 web applications

There are 2 independently functioning web applications. Web-app1: (Flutter+Django+Postgres). Web-app2: (Angular+Spring+Postgres). Each of the web-apps has its own user database and are functioning ...
mAsK's user avatar
  • 3
0 votes
1 answer
48 views

Validating REST API requests against previous requests as part of a larger process

I am building a REST API for warehouse inventory picking. I have a very shallow understanding of REST, so to me that just == stateless and try to make your URL mappings nouns instead of verbs. The ...
secondbreakfast's user avatar
-1 votes
1 answer
2k views

How do I know if my nodejs application is stateless or not?

According to documentation from PM: https://pm2.io/docs/runtime/guide/load-balancing/ To make use of its load balancing feature which uses node's clustering to spawn multiple node processes, I need a ...
jeff's user avatar
  • 13
5 votes
2 answers
3k views

What is the benefit of having separate web servers and application servers?

Most of the web applications that I have seen developed in my organisation , have the following components : JS App (from browser) -> Web server -> Service(s)/Application server(s) -> ...
takasugi's user avatar
  • 293
0 votes
1 answer
268 views

How do Asynchronous Webserver (FastApi, Quart etc.) handle many Requests better than synchronous Webservers

I started using Pythons async features and want to fully understand their use cases. I see webserver like FastApi or Quart which use async features. How are they working different from webservers like ...
hadamard's user avatar
  • 111
0 votes
1 answer
3k views

What would you name the different DTOs for the methods "GetUser" and "AddUser"?

I have a web service with the methods GetUser and AddUser, and some DTOs (Data Transfer Objects) GetUser: retrieves user information, as a DTO called UserGet DTO AddUser: takes a DTO called UserAdd, ...
symbiont's user avatar
  • 111
28 votes
5 answers
6k views

I'm not seeing 'tightly coupled code' as one of the drawbacks of a monolithic application architecture

One of the most common things I see when discussing pros/cons of microservice vs monolithic architecture is that monolithic applications have, or always trend toward, 'tight coupling.' To be honest, I'...
Bob Dole's user avatar
  • 421
8 votes
2 answers
1k views

How does user authorization work in a Microservice architecture

I'm learning how to design a Microservice architecture. For example, here is a simple Microservice architecture: I'm kind of confused by the Account Service. As we know, for a web service, normally ...
Yves's user avatar
  • 203
2 votes
1 answer
852 views

Best approach for developing a stateful computation-heavy application with a rest-api interface using python?

I want to develop an end-to-end machine learning application where data will be in GPU-memory and computations will run on the GPU. A stateless RESTfull service with a database is not desirable since ...
ardaasik's user avatar
1 vote
1 answer
76 views

Ordering of analytical events

My team is working on an analytics system for the web app. The web app has a service-oriented architecture, and all events are gathered in one centralized analytics service. The system is sending ...
Toshakins's user avatar
0 votes
1 answer
729 views

Design a correct microservices architecture with data relations

I just started thinking about building a microservices architecture for learning purposes. I understood that microservices are split, and they should be independent, even when storing data, but what ...
DanielVip3's user avatar
-2 votes
1 answer
332 views

Handling Legacy Database with Spring Boot Java

We are given a task to create an Web Service API for a mobile application. The problem is we have to use a legacy database that is not normalized and its very tedious to work with. We are accustomed ...
Shareem Gelito Teofilo's user avatar
1 vote
2 answers
809 views

Can a monolithic architecture provide more than one API?

I have been researching microservices and monolithic architectures, and I can't seem to find the answer to this question. From my oversimplified understanding, a monolithic applications uses the same ...
Carlos Coelho's user avatar
1 vote
1 answer
144 views

Consuming complex JSON service that does not have schema

Hi I have this weird situation where I have a JSON producing service that represents a very complex object graph and this bject graph does not have a JSON schema that it is based on. The reason for ...
Alexander Petrov's user avatar
1 vote
1 answer
328 views

Architecting multiple codebases calling our public API + private API for first-party applications

Currently, we have the issue where we have two codebases (API & Website) calling the same database (along with some duplicate business logic) and we want to streamline this so all requests are ...
Countach's user avatar
  • 113
4 votes
3 answers
653 views

Why not use SQL to query an API instead of GraphQL?

nalzok posted an interesting question over a year ago: "Why not use SQL instead of GraphQL?". Respondents seem to suggest three main problems: One should not directly expose one's database ...
davemackey's user avatar
0 votes
4 answers
754 views

When to throw error in response vs save error in database for POST API

I am creating a API to create Personnels of X city. Assume that there is a generalised service for creating personnel of any city and I want to call this service for X city personnels from my API. ...
hatella2's user avatar
0 votes
1 answer
591 views

Is this an anti-pattern to have a service have both APIs and listening to events?

I am planning to make a service which will have simple REST APIs and will have a database in backend. I also wanted to add a logic to listen to notifications emitted by other service and there is some ...
hatella2's user avatar
1 vote
1 answer
89 views

Multiple webservices on a single port

I am developing a webservice, which offers different services, but currently under different ports. Existing services like GitHub or GitLab also several services, but I am wondering how they can ...
Daniel Stephens's user avatar
-1 votes
1 answer
327 views

How does a robust http server handle requests?

I have written many http(s) servers in Node.js and just take for granted that I can receive many requests and all IO operations are async. However, now I would like to try and implement an HTTP server ...
Lance's user avatar
  • 2,585
1 vote
1 answer
200 views

Sending an xml message as the payload to a web api

I have been tasked writing a "fire-and-forget" push web application, that can push high-volume XML messages (of several types) to multiple client endpoints over the internet (HTTPS). I don't need a ...
simonalexander2005's user avatar
2 votes
3 answers
3k views

@OneToMany relationship in a microservice environment

I am coming from a typical monolithic background and I've been experimenting a lot with Spring Framework. I have also build some simple microservices communicating with each other etc. Now I want to ...
Ilias Mertzanidis's user avatar
5 votes
2 answers
3k views

Multiple DTOs vs Single DTO vs primitives

I'm wondering what's the best approach, and its advantages, when specifying parameters for the Web Service methods. Best to explain it through examples. In my (SOAP) WebService, used by a Xamarin ...
Jeff Nama's user avatar
0 votes
2 answers
133 views

Should there be a separate service for creating asynchronous job?

Say, our team owns 3 services, one is responsible for creating persons, other is responsible for creating buildings, and 3rd one is responsible for creating jobs. Also, we have one website, which is ...
hatellla's user avatar
  • 171
-2 votes
1 answer
154 views

DIY email service vs MailChimp and pals

I need to set up newsletter signup for a site. Initially, I was eyeing services like MailChimp and SendPulse, but I'm not comfortable with their prices and I'm not really keen on sort of giving up ...
Zoltán Matók's user avatar
3 votes
2 answers
4k views

Combining PUT and POST on the same resource

I have the resource OrderRequest which I guess can be qualified as process. The OrderRequest can be create of update. The create should be idempotent, because creating the same order request 2 times ...
Alexander Petrov's user avatar
1 vote
2 answers
441 views

Multiple thread invocation in Rest Web Service

I have a scenario in our Web Application. GUI invokes a REST web wervice and further web service calls a procedure. However, the procedure returns data properly for most of the scenarios. In some ...
Sanju's user avatar
  • 31
1 vote
0 answers
63 views

Handling 3rd party OAuth2 tokens

After some extensive research I still don't know how to properly implement the following case. I think this question answers something similar, but I'm not 100% sure (Should client have access to 3rd ...
johannesp's user avatar
  • 111
1 vote
1 answer
364 views

Is it a common pattern to put create/update/archive as one process?

Traditionally it's assumed that we should treat create read update delete as separate concepts. However, I have noticed that the following pattern seems more usable for certain contexts [create, ...
oooiiiii's user avatar
  • 133
0 votes
2 answers
151 views

Should I create one large initial event or break down in smaller events?

I'm experimenting with event sourcing for an application we haven't build yet. No, I won't implement this without any thought, I'm just experimenting. My domain model looks somewhat like this. The ...
annemartijn's user avatar
1 vote
1 answer
139 views

JEE Gps Tracking System Design

I have created a real-time GPS tracking web-based system using Java Servlets as a backend solution whereas the front end is using javascript with ajax requests and WebSockets. (Both the front and ...
Papa-rapa-beo's user avatar
0 votes
3 answers
468 views

how to build microservices that also have GUIs

In a microservices architecture where each component does one thing, how do you handle GUI logic? How do you avoid building a front end web application that has a lot of smarts built into it where it ...
dot's user avatar
  • 541
0 votes
3 answers
829 views

How to calculate the costs for an on-prem API request in terms of money?

My manager asked me how much it costs (in money, currency, $) to make a REST API request from our client application to one of our services. We do not use cloud, we have on-prem servers. The payload ...
greg b's user avatar
  • 71
115 votes
17 answers
24k views

Why should 'boneheaded' exceptions not be caught, especially in server code?

I am confused because in quite a few places I've already read that the so-called 'boneheaded' exceptions (ones that result from bugs in code) are not supposed to be caught. Instead, they must be ...
gaazkam's user avatar
  • 3,883
-3 votes
2 answers
162 views

Options for managing a multi-purpose web service?

I have a web service that serves two purposes. On a weekly basis, it syncs records from the GIS DB to a workorder management system's database. On a continual basis, it serves up the records to a ...
User1974's user avatar
4 votes
4 answers
1k views

How to model correctly a non persistent action via REST API

Hi I have a Order this order needs to be sent to an order system. There are several oprations that can be performed. Create Modify Check-Modification (this happens on existing order) Simulate ...
Alexander Petrov's user avatar

1
2 3 4 5
13