1

I am making a data visualization application in Unity game engine that simply shows data in a 3D environment using google maps API.

I am using the three-tier architecture to explain the application. It has the following layers

  1. Presentation Layer Shows the visualization
  2. Logic Layer Transforms the data as per logic from the API and gives it to presentation layer
  3. Resources Layer google maps

My question is, where does the API call module goes, the one which requests data from google maps. Should it be in-between the logic and resource layer as another layer?

Or am I doing something wrong here...

Architecture Diagram

1 Answer 1

2

In a typical three-tier architecture, the logic layer is responsible for everything that isn't presentation and data.

That includes (this is not an exhaustive list) calculations, processing data, making decisions, etc. But most applicable to the question, it is responsible for moving data between the other two layers (usually transforming it on the way).

three-tier-architecture

So any component, application, software that you want to articulate that makes the call to the API in the data/resource layer exists inside the logic layer.

If you wanted to split the API call module out of the logic layer, you'd then have a four-tier architecture (perfectly good) where your logic layer is split into a business logic tier and a data access tier.

four-tier-architecture

Image sources are https://en.wikipedia.org/wiki/Multitier_architecture#Three-tier_architecture and http://vbsoftwaredeveloper.blogspot.com/2013/05/4-tier-ioc-application-converted-tier.html

3
  • In a 3-tier architecture, is it theoretically correct to further divide the logic layer into sub-layers? or would that be a n-layered architecture?
    – K Test
    Feb 28, 2020 at 15:15
  • @KTest That would be n-layer or four-layer. I've made an update to my answer
    – K Mo
    Feb 28, 2020 at 15:19
  • Thanks a lot for the explanation, cleared my confusion
    – K Test
    Feb 28, 2020 at 15:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.