What is the best approach of building SAP Hybris application from scratch? - sap-commerce-cloud

I'm trying to build my first app on Hybris, but I'm not sure what is the best approach to build such applications. Let's say I sell flowers in my store. Currently there are 2 ways how to do it:
Create accelerator template and then reconfigure application.
Building app from the beginning.
The first solution may look very attractive, but I don't think it is better solution because:
Hybris doesn't provide an accelerator for my specific solution (flowers), application reconfiguration may take a lot of time.
Some accelerators contain more that one store - other stores should be removed.
The mess in the database. I have to spend time and understand which tables should be removed.
The second approach seems the most logical, but in this case I have some doubts, because the speed of development will be significantly reduced. Moreover, I think that developing a simple store on Spring Boot will be much faster than learning the Hybris platform's extensions and how they work together.
In this case, how should I start develop my application?

Honestly, I don't have experience with building complete SAP Hybris application from the scratch yet, but I have some experience related to development of the SAP Hybris extensions, so I'll try to provide my potential approach because I don't see many answers here.
I'd do it as follows:
Get the whole commerce suite
Run one of the recipe with the installer script (choose one, which will be the best for you - one of the most popular/common recipes is b2c_acc)
Remove unwanted extensions from the localextensions.xml file if necessary
Add another extensions, if you need them
Depending on your use case, create your own extension basing on the one of templates with ant extgen task inside the hybris/bin/platform/ dir (e.g. yacceleratorstorefront, ybackoffice, yempty, etc.)
Add your custom extension (or extensions) to localextensions.xml file
Start your development within your custom extension created out of available template
I know, it's kind of "specific" platform. I hope this answer will help a bit.
Cheers

Related

Question about commercial use of generated JHipster apps

I'd like to get some business apps up and running quickly with the use of JHipster, which seems like a solid approach; assuming it is allowed. Is the commercial use of a generated JHipster application allowed and if so, what are the proper steps to take in in order to not infringe upon any terms and conditions of open source?
I apologize if this has been asked previously.
I really just need to know how I can go about using an instance of a generated application for something other than an open-source project.
Sincerely,
Art
There are many closed source applications originally generated by JHipster. The generated project is fully yours.

How do I create transferable dll's for a specific website functionality?

VS2013 update 5, MVC5 using Areas
I have a stand-alone function programmed for a website. The functionality is a specific user interface to collect survey responses in a particular way. It has several controllers, a model and a group of views. The functionality is completely contained in an Area of the project, except for the Shared _Layout file that provides the main menu for consistency.
'Is it possible for me to' / 'how do I' compile this Area into a single or set of .dll file(s) that I could then add conveniently to other websites? I'm assuming creating something for transfer/download is very standard functionality. For example, I used Elmah.MVC for this site. What I want to do is pretty much create a package that can be downloaded in a similar way to how we integrate Elmah.MVC into a site. (Be certain I'm not talking about creating error logging software, I'm only using Elmah.MVC as an example of software that is easily integrated into other website applications.)
I've never compiled any website functionality into a .dll(s) for use elsewhere and would appreciate either some specific guidance, or perhaps what would be easier is to provide a link with a good step by step tutorial or explanation for how to do this. Most of what I've found on the web describes bits and pieces of doing this, but it's not enough for me to feel confident with it.
It seems to me there are a lot of 'moving parts' to taking a particular piece of an MVC application and turning it into something that is easily added to other projects.
A particular issue I don't quite grasp is the difference in downloaded packages between getting code and getting just the .dll(s). For instance, when I download an MVC5 site, I get controllers, models and views, but when I download Elmah I get a .dll and no code files. Also, I do understand the concept of transforms, but I'm just struggling right now with even getting from my programmed application into a 'package' regardless of the transforms that make it easy to integrate into another website.
These are just some of my questions I have about how to perform this particular process in developing deliverable and/or shareable software.
What you are looking to do is create a portable MVC Area project. A Portable Area is a set of reusable multi page functionality can be dropped into an application to provide rich functionality without having to custom build functionality that is literally the same in every application. An MVC Portable Area is really just a dll that contains the views, controllers, scripts, etc… needed to use in a website that is either a Web Forms website or an MVC website. A developer can use them for a reusable widget or a complete engine. I have actually used them for both. Here is a link with some basic info to get started. http://elegantcode.com/2012/04/06/mvc-portable-areas/

Extracting a Module from Orchard

I am having a little problem in my workplace where we have a IIS 6 server where Orchard (1.7) will not run. We are planning an upgrade but that's going to take some time.
Since we are using this site on IIS6 only to run one particular custom module we wrote for Orchard (basically a MVC module with its own Controllers/Actions etc.) I was thinking that a temporary solution could be to rip that module out of Orchard and run it independently.
Of course this extraction needs to take into account how many ties I have with the framework. I was wondering if there is some kind of guide to perform this and if there is something I need to take specially into account.
I am using the Users in Orchard so I would probably have to rewrite some users code. I am also using the Authorizer, which again may mean I need to re-wire something else.
It seems like a daunting job so I am looking for some quick tips on how to proceed if you know any.
Thanks a lot!
It all depends on what components you actually use within your module.
Hard to write any tutorial on this, really.
Regarding Orchard.Users - you could drop all related code usages and rely on the default ASP.NET roles-based authentication/authorization model.
If dependency injection is what you want to keep, then you need to integrate it yourself (for Autofac, but other DI containers will also work). Feel free to copy and change any Orchard components that you use, stripping the unneeded code.
In my opinion the hardest thing to strip out and replace would be any code that relies on content items - hope you don't have it. Rewriting this pieces sounds like an overkill. But if you just use IRepository, going for plain NHibernate or EF instead should be quite easy.

How is your approach for creating your own set of controls aka own Extensions Library?

What is your approach for creating your own set of controls aka own Extensions Library? After a few years of Xpages development we have a huge set of controls that are general purpose for building UI, some web services etc. (Probably as most other developers.) When we start a new project now we have to copy the entire stuff from one database to new one which involves controls, jars, css, images, JAVA code ... and then you completely loose control to maintain some central version of this controls & codes, everything is scattered among several projects/databases and things get messy fast.
We have thought about creating our own extension library as described here
http://www-10.lotus.com/ldd/ddwiki.nsf/dx/Master_Table_of_Contents_for_XPages_Extensibility_APIs_Developer_Guide but there is not enough documentation for this topic and the entire development process is quite complicated (at least seems to me. I tried two times based on docs above going through eclipse plugin project -> feature project -> update site and still having some bugs around)
What is your experience and approach for creating and maintaining shared Xpages controls in your Domino environment? Is there some hidden feature we miss here that can help us?
Take a look at the XSP Starter Kit on OpenNTF and the XPages SDK to setup an eclipse environment for plugin development. You'll also want Eclipse IDE for RCP and RAP Developers. Install the starter kit and SDK into eclipse and you should be all set.
The starter kit is a sample plugin with all kinds of examples of phase listeners, components, etc. Once you want to deploy your plugin, create an update site from within eclipse and use the Update Site NSF available on your server install to place your update site. Once that's done, you can replicate that NSF to any other servers that may need the plugin.
For more information about the starter kit, take a look at this slide deck. There is also a github project for the starter kit. Documentation for the XPages SDK can be found here. And a video for setting up the SDK is available on youtube. Lastly, here's the documentation for setting up the update site NSF.
While we haven't gotten to that yet in XPages, our model for regular Notes design elements is to have a central template that contains the elements that are shared, with those specific design elements marked to inherit from that template. Sometimes, a database inherits design elements from two different central templates.
That way, those centrally controlled design elements remain the same in all databases.
I would recommend looking at some example's on github for how they have library/components setup. One of the more simpler examples that has just a single component built into a Library is Steve Pridemore's App Layout Extension...https://github.com/DominoDev, Another good one is Nathan Freeman's Starterkit: https://github.com/the-ntf/xspstarterkit. Hopefully these will help you get the file structure down on which files you need and how they work.

Developing a DotNetNuke CMS website

I am a junior developer and I have just graduated from university this year. I am working private with some people and I have just been given a music website to develop using DotNetNuke. I have a some experience using DotNetNuke which I have gained making small modules that take care of certain functionality on a webpages but I have never taken on a whole website before. I would love it if some one would give me some guidence on how to approach this project and answer some of my questions.
What are the steps involved in developing a dotnetnuke website?
How different is it from a developers perspective to develop a dotnetnuke cms website from a cms website which was developed from scratch?
When it comes to the database do you add tables to the database incrementally as you develop new functionality or do you plan everything in advance and create tables and stored procedures at once?
What are the steps involved in developing a dotnetnuke website?
Pick your version (if you're starting now, pick 5.1.1)
Installation (use Source package locally, Install package everywhere else)
Settings Configuration (performance, security, user info, etc.)
Adding & configuring core/third party modules
Adding & configuring third party skins
Custom Extension (typically module or provider) Development
Custom Skin Development
How different is it from a developers
perspective to develop a dotnetnuke
cms website from a cms website which
was developed from scratch?
Very. When you're starting with an established CMS you're inheriting solutions to tons and tons of solved problems. In the case of DNN, you have a substantial framework at your disposal. The focus will be more on learning and leveraging the existing API/features. If you're starting from scratch you're providing that foundation yourself. Using an established CMS is not necessarily better than the other - it depends on what you're trying to accomplish. If you require fine-grained control over everything and you want a great learning experience, rolling your own may be the best way to go.
When it comes to the database do you
add tables to the database
incrementally as you develop new
functionality or do you plan
everything in advance and create
tables and stored procedures at once?
No matter what your project is, I'd suggest doing things as they are needed and not before. I think "doing everything in advance" would be impossible/horrible anyway. The heart of this question is really going to be defining your development process - I don't think this would necessarily be any different than in other projects. I like to define the features I want, organize them based on their relation to each other (which should come first due to dependencies, etc) and start implementing them one at a time and give each one the attention it needs.
You may also want to look into Lee Sykes' tutorials on module development using OpenWebStudio. However, I'm more on the design end, mainly just skinning, configuring, SE optimizing sites and matching client needs to our library of licensed 3rd party modules. However, the DNN community is VERY supportive and VERY helpful. There are some great resources out there, and I've found several blogs by the core development team to be essential for helping me wrap my head around the DNN framework.
Keep with it, and don't be scared to ask questions.
References:
www.dnncreative.com - Lee Sykes' Site, many tutorials on the how-tos of the DNN system. It's well worth the yearly subscription IMHO.
www.dotnetnuke.com - The main site for the DNN community
www.snowcovered.com - Central (AFAIK) site where many module developers sell their products, everything from skins to modules.

Resources