CommerceTools Initial Load - commercetools

What is the best way to import >5 million records of customer into commerce tools?
I only need it to load initial load but I don't need any sync services between external sources and commercetools multiple times
process of finding delta can be done outside.
I went through the import API documentation https://docs.commercetools.com/import-export/
#option 1: Impex UI, I believe its node backed application. Does it uses Import API?
#option 2: Project Sync. It uses Import API and abstract batching, http request etc
#option 3: Import API SDK. It abstract http request
With large dataset to import for initial load, it sounds like #2 Project sync would be better choice since it has batching. It looks like it calculates delta before syncing to commercetools which I dont need since I want to use it for initial load.
Which option should i use?

The Import API is a good choice for customers and order imports as the import api will resolve customer references on the orders by key.
You can also consider using the API directly using the sdk of your choice.
Does that help?
Best Regards
Brian

Related

Generate shareable link feature in Django?

I have a Django Rest Framework application that is fed in data from a csv. I then use React to create dashboards and Widgets from that data. I want to be able to generate a link to share a read-only version of any dashboard, much like in Google docs etc. Anyone clicking on that link will be able to see the dashboard with all the charts and analytics etc. The link can be shared much like how you share a Google Forms link. I'm not sure how to go about doing that. Any help / pointers would be appreciated. Thank you!
I think theoretically you need to use a router on your react app (e.g. https://reactrouter.com/ ).
If you're using create-react-app, you can also refer to https://create-react-app.dev/docs/adding-a-router/#:~:text=Create%20React%20App%20doesn't,is%20the%20most%20popular%20one.) .
With this you can directly read parameters on a certain page within your react app, that you can then use to build a concrete call to the backend, to retrieve the necessary data to build your dashboard.
The 'link builder' functionality most likely needs to be implemented on the backend, so you can have the necessary parameters you need to gather the necessary data, maybe by using query strings.
If you want to make it more complex, you would need to implement on the backend a kind of tokenized access, that could store the full call parameters on the backend side, and associate them with a token of some kind, that you could then provide to your clients.
e.g. : http://djangoappxpto.com/link/12345abcd points to a react page component that then executes a fetch to http://djangoappxpto.com/api/getStats/12345abcd which once received by python would internally mean something like http://djangoappxpto.com/api/generateStatsReport/?param1=a&param2=b&param3=w&param4=aa .

How to implement real-time comment system in a django-react app with channel/celery/redis etc..?

I have a web-app with Django backend and react frontend where inside an organization or company, there are multiple users. Now, I am trying to implement real-time commenting system where if one user types any comment and posts it, another user will be able to see it without refreshing the page.
I have seen some examples of asynchronous tasks using celery with redis but couldn't find any with react implementation.
What would be a good approach towards achieving the real-time comment system in the react/django app?
Here is an example of simple tasks with celery, redis and WebSockets (Django Channels) and frontend in React (and docker for deployment). The task state and progress are updated over WebSockets https://github.com/pplonski/simple-tasks
The other option will be long-polling, the user will not need to refresh the page, but React will make requests every few seconds to get new data (simple and solid approach). I've seen this approach in many (many) applications. A few years ago I will be afraid of such implementation (too many requests). But now, I will select this approach because of its simplicity.
There's also CollabKit which provide a React commenting system. https://collabkit.dev

Recommended pattern to fetch data from API's in React

We are writing dash board app in React that requires us to fetch data from remote API's asynchronously. Until data s fetched, dashboard widgets need to show a hour glass or something similar. Using hooks, using Redux/Saga, using a local data access service are some of the approaches we considered. We are mostly biased towards using Redux/Saga for this but want to check if there are any standard/recommended patterns used by react community.
Recent days I've seen these two libraries circling around community posts, haven't tried them myself, but maybe will be useful to your project:
https://github.com/zeit/swr
https://github.com/tannerlinsley/react-query

SAP PowerDesigner Data API

I am want to create CDM in powerdesigner using import functionality. I have explored the option of importing excel but this requires user to refresh the imported excel in case of any changes.
What I want is to call an API, which will provide json/xml data, from powerdesigner, either desktop or web application, to generate CDM . Is this option available in powerdesigner? if yes, then how can I do it?
There is quite usable Java API which you can use basically to do anything can be done manually in PD. So you can process almost any input/ouput file to create various diagram.

Add databound dropdown to Azure API App logic app shape

I have developed an azure API app that I am using in a logic app. For the purpose of this post, it doesn't matter what my app does.
In my logic app shape (Azure API App) I have managed to render a drop down list by making one of my API post params an ENUM. Then changing the swagger / swashbuckle configuration to render the definition differently.
This is a good start but I really need a data driven drop down that reads it's data from a constantly changing data source (blobs, documentDB for example but it doesn't matter).
I can't find any posts on this.
All help will be greatly appreciated
Great question - we have on our backlog to support what we call "Dynamic Swagger" that lets you do just this. I'm hoping it will be in production near the beginning of March. In the meantime you will need to just enter in the values of those fields manually.

Resources