microservices – Thought process required to design domain aggregate in micro service architecture?

I am using DDD pattern in login micro service used in employee management software. Here Organization/Company is an Entity and User is one more entity.

What are my aggregates in this case, if i think with project in mind which is login i will have only one aggregate(user aggregate) but if i think as business in my mind i will get two aggregates(Organization,User).

I might be wrong too with above aggregates. My basic question is what is the thought process when designing a aggregate in micro service? is it with respect to project or business as whole?

Micro services architecture for search engine

My purpose is to build a search engine as google. I thought to build it base on a microservices architecture. We have principal steps: crawling (the process of finding new links) scraping (the process of collection and extracting data items) indexing (the process of attributing index to each document as a key word for each doc) and ranking (the process of attribution a score for each page based on several factors). I am thinking about Cassandra to store data crawled and elastic search to index it. But the question is any advises on database to use for each service and how to communicate between the data stored in each service in a fast way.

applications – How to fix my micro SD card that became a read-only memory card?

Since the Android external memory card has turned to read only (also known as SD card write-protected) all of a sudden, I can no longer add, write, or delete things from it.

How to fix the SD card that mounted as read only?

Is there an application to solve this problem?

I will find micro niche and do keyword research for amazon affiliate for $15

I will find micro niche and do keyword research for amazon affiliate

Are you an Affiliate Marketer? Or planning to do?

If you are, then you must be looking for a niche/idea which is low competitive and easy to rank, right? Well, I’m here to help you.

>>>>>>>>>>>>>>>>>>>>>>>>>>>Micro Niche & Keyword Research<<<<<<<<<<<<<<<<<<<<<<<<<<<<<

I will find micro niches for you that are low competitive. You will have niche ideas that will be low competitive and easy to rank. In this service you will get:

  • 2 niche ideas
  • 20 focus keyword research (commercial + info)
  • a list of competitors
  • Contents idea (if required)

I will provide you a full report in an excel sheet. You must remember that content is the king in SEO. And you just need a proper focus keyphrase to write the right content.

If you have any special requirements, feel free to contact me. I will always be glad to respond. It would be better if you contact me before placing the order.



Thanks!

Taher Sohag

.(tagsToTranslate)keyword(t)amazon(t)niche(t)affiliate(t)nicheresearch(t)keywordresearch

microservices – Routing with micro services

I’ve decided to create my project following a micro service architecture. I have a products service and a reviews service.

The products service essentially stores all information regarding a product whilst the reviews service stores reviews for a product.

I’ve decided to keep these separate from each other as I would like to scale the reviews service at some point in the future.

My products service has a single controller with a bunch of actions, the route for this service is api/products

I realised that on the reviews service I need to create an endpoint to grab all reviews of a product but not sure what the route should be as i feel like because it’s the reviews service the routing should be named like api/reviews but surely you’d expect the route for this action to be api/products/{id}/reviews

How should the routes be named if each service has to be independent from one another?

Cache on micro sd – Android Enthusiasts Stack Exchange

Stack Exchange Network


Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Formatted micro SDHC card but partitions and files remain

I have 2 Samsung EVO micro SDHC cards that I was using in a Raspberry Pi. I’m now trying to format them on my Macbook Air running Big Sur on Apple Silicon and have tried two methods for formatting, and they ran without errors but the files and partitions remain:

1 – SD Card Formatter – tried both quick format and overwrite format

2 – sudo diskutil partitionDisk /dev/diskN 1 MBR "Free Space" "%noformat%" 100% (diskN replaced with disk3 in my case)

Does anyone have any suggestions? I’m hoping I don’t have to throw them out and order new ones.

web development – How does user authorization work in a micro service architecture

When developing and deploying actual micro services, you do not want your consumer to access the microservices directly for several (main) reasons:

  • it introduces heavy coupling on the client to your internal representation, to a certain degree this is similar to a case where you would expose a database directly,
  • it complicates integration on the consumer side, because they need to remember where each service lives, on which URL,
  • it is difficult to perform global checks and filters, such as API throttling,…

You have encountered one of those problems, which will certainly lead to others in the future.

Microservices should be internal in general. They may talk to each other in a synchronous (request/response) manner, although asynchronous (through events) communication is preferred, which makes it easier to deploy microservices separately, and also leads to more proper microservice design regarding their separation. With publicly accessible microservices, if you need to expose them to the outside world, put an API Gateway in front of them.

API Gateway acts yet as another system, through which flow all requests. It’s usually pretty light weight and responsible for routing of requests to appropriate internal microservices. But it has one great added benefit. You can put necessary global operations in it (since it’s your entry point). This includes authentication (who a user is) and optionally authorisation (is the user permitted to).

Since the API gateway authenticates your user (or otherwise rejects the request as a failed auth) and then forwards the request further to an internal microservice, the microservices themselves do not need to bother with authentication anymore. It’s guaranteed to be performed before they’re called, and they can trust the id of the user in the request. For most calls the id is the only thing necessary (without any additional checks), therefore in such context the operations needs not to bother with user logic at all.

With authorisation, it’s a little bit different and depends on the context. If there are simple rules such as: “This endpoint may be called only by users with the role admin,” then such rule can probably be placed in the API Gateway, to reject the request before even routing it into the microservice, which would reject it anyway. With more complicated authorisation closer to the business rules, it’s necessary that the given microservice keeps their copy of a user and checks against its database by itself (circumventing the synchronous like communication).

API Gateway provides also another benefit for your ecosystem. You can introduce multiple backends for your internal microservices, e.g. one for e-commerce, one for some mobile application,… thanks to which the consumer worries only about the exposed endpoints and is not overwhelmed by logic which needs to be internally available in your system but is only consumed from different contexts (therefore exposed as a different backend).

Why is synchronous communication frowned upon? It’s an easy mechanism how to obtain data among microservices, but it leads to direct coupling, because of which you need to introduce patterns like Circuit breakers, and starts to introduce single points of failure in your system, where a single failing microservice (on which tons of other microservices depend) may collapse your entire system. Event-driven systems are more resilient to this type of failure.

partitioning – Error formating micro SD card is write protected or read only

‘error wiping device:Failed to open the device’/dev/sdc1′(udisks-error-quark,0)

Attempted fixes with Windows

When trying to format by right-clicking and reformating via the Windows Explorer, the first thing I encountered that the card was write protected.
and i dont have switch lock on the SD card i have checked

I tried removing read only permission through command prompt using list disk there i got that disk write protection is off 0

Attempted fixes with Linux

tried fdisk -1 and gparted nothing happens
i get this error when tried to format in files ‘error wiping device:Failed to open the device’/dev/sdc1′(udisks-error-quark,0)

architecture – What is the most common approach for microservices to access data managed by other micro services?

Both are viable. They have their tradeoffs.

First one is easier, but if Order service is down, so is Fullfilment service. It also becomes a problem with overall stability. If a service depends on 3 other services, and those have stability of 99.5%, then the service itself would have 0.995^3 = 0.985 = 98.5% . This might be unacceptable. And when you have dozens of services with many instances, these numbers quickly add up.

Second is more difficult, but Fullfilment service can work even when Order service is down. It also allows the Fullfilment service to store the data in a way that is easy for it to consume. This might not be true for whatever API the other services provide for it.

Third option is to use ‘delayed’ creation. In this scenario, the Fullfilment service tracks the state of it’s request in persistent storage and starts it in ‘is being fullfilled’ state. Then, it sends asynchronous message to Order service, which Order service will process when it is up and ready. Once it is done, it will send response back to Fullfilment service, which will continue in the processing. This is different form of complication than keeping copy of the data, as you need to keep track of fullfilment state and revert it if something goes wrong (eg. with saga). And it requires client of Fullfilment service to know that it’s request can be in ‘to be finished’ state. But it gives you advantage of high stability and no need to keep duplicate data.