2. Sitecore Team Leader at SoftServe.
Consultant, who always advice to find the best solution for
client issues. Over 8 years in .net business. Loves to inspire
devs, teams and go through the newest technologies stack.
Between those activities likes dancing, gym and sport in
general. Favorite color: yellow !
Twitter: robert_debowski
Blog: http://JustSitecoreThings.net
r.debowski@yahoo.com
rdebow@softserveinc.com
4. xCommerce = Sitecore Experience Commerce, since 9 version
What is the xCommerce?
Many changes comparing to Sitecore Commerce 8, like:
• ASP.NET Core based on
• oData RESTful Web Services
• New UI
• Full lifecycle Order Management, Promotions feature etc.
13. Hosting!
• Kestrel
• Hosting server
• It was launched by Microsoft along with ASP.NET Core. All ASP.NET Core apps
utilize a new MVC framework and the Kestrel web server.
• It is much more faster than IIS
Sitecore Commerce Engine
• This GitHub project has been
archived. Active development has
moved to
https://github.com/aspnet/AspNetC
ore (Part of ASPNET Core Runtime)
15. Post-(it)-man !
Ok – but how to check it, debug?
• Turn of SSL verification
• Turn of AntiForgeryEnabled on Authoring
• Import Postman
samples .... from
SDK
20. A named, versionable and variable set of data that can be used as facts within
behaviors to influence behavioral outcomes. (Source:
http://commercesdn.sitecore.net/SitecoreXC_9.0/Developers-Guide/Sitecore-XC-
9.0_Developers_Guide.pdf)
In simple understanding we can treat
Policy like a config or setting file in some way.
Policy
21. • Independent features
• Only accepted way to extend Commerce Engine
• Don’t remove default ones just like that ;)
Sitecore Commerce Engine - Plugins
23. • You can create your own pipelines and hook
into pipelines defined in other plugin
• Similar to standard Sitecore pipeline
mechanism
• In SXC9 they are in the code not XML
• Agregate SXC Blocks
• Comparing to XML approach No
„ShowConfig.ASPX” but JSON preview
• In Commerce, there is no config patching
facilities. Instead we can create our custom
plugin and can patch our Blocks through the
code.
Sitecore Commerce Engine - Pipelines
24. • Equivalent for Sitecore processors
• Chaining calls
• Remember about returning element
Sitecore Commerce Engine - Blocks
27. OData - OData (Open Data Protocol) is an OASIS standard that defines the best practice
for building and consuming RESTful APIs.
Sitecore Commerce Engine - OData
ODATA
ATOM JSON
HTTP
28. It’s so super cool till now, but what to do
to use new stuff in Sitecore side ?
Should we know something more?
Well.. Yes, we should.
We cannot use in Storefront references to
.NET Core features from SXC Enginge
29. Service Proxy acts a middleman between your
engine code and your storefront code, allowing
you to reference the types & controller
endpoints defined in your engine, from your
storefront code.
Sitecore Commerce Proxy
Commerce
Engine
Service
Proxy
Storefront
30. How to use Sitecore Commerce Service Proxy
Build your Engine
with custom plugin
Deploy engine or
run on port 5000
Add Service Proxy
project to your solution
In VS2017 expand
Connected Services
For CommerceOps & CommerceShops right click
on them and select Update OData Connected
Service (This will hit the Metadata data endpoint of the engine
and rebuild the generated code files for each)
Reference the updated ServiceProxy project in your
Storefront project and start to use your custom
engine entities.
31. Some extra feature which came in SXC 9.0.2
Composer
Demo
IF we have time for this now, let’s make some
Composition
- Entities can be extended by adding components to the Components property on the entity.
- Components are simply classes that are injected into the entity by a plugin through a Pipeline Block (more on how to create custom plugins in a separate post).
- A good thing about this pattern is that it allows us to inject components into an entity without interfering with components injected by other plugins.
POLICY
Entities can also be extended by adding Policies. A policy is basically a set of rules for an entity. It is a class that defines a set of data that can be used by business processes to determine behavior. E.g. you could define a policy for the cart entity that sets the maximum cart value or the maximum number of line items. In essence, policies are code based configuration settings.