How to access data from Crafter CMS repository in a remote application? - alfresco

My use case is :
Authors uploads images and enter meta data about images (or blogs) such as image description in Crafter CMS. Admin approves/publishes the images. As soon as this is done, a separately developed Java web application ( public facing) not linked with Crafter CMS sees this new content which shows up in faceted search results as the end user is interacting with this Java web application.
How above can be achieved using Crafter CMS (Community Edition) ?
Crafter CMS components cannot be used in remote Java application (tomcat) which has direct access to content (originally coming from Crafter CMS) in cache memory. This remote Java application has its own solution for search based on elasticsearch. Better way to ask this question how Crafter CMS can store content in remote repository living in the same server running remote Java application.

To address the use case: Crafter CMS is composed of several subsystems. Crafter Studio (content authoring subsystem) would be used by the authors to upload/assign metadata/preview/approve the images within the context of your app (via in-context preview). Your public-facing Java app would be built on Crafter Engine (Java/Spring-based middleware subsystem), which provides APIs to get access to the content published from Crafter Studio. Crafter Engine includes an integration with Apache Solr for faceted search.
--
To clarify the confusion: Alfresco is better characterized as an Enterprise Content Management (ECM) platform for managing all types of content - documents, digital assets, corporate records, along with web content. Crafter on the other hand is a web content management system (traditionally called a web CMS), specifically for building and managing the front-end UI/UX and back-end functionality of digital experience applications (modern websites, mobile apps, AR/VR experiences, video-sharing sites, etc.). Crafter CMS originally was built as a web CMS app on top of Alfresco, hence the tight integration between the two.
Starting with Crafter CMS version 3, Git is the main underlying repository.
Crafter still integrates with Alfresco (via CMIS) as an option, to leverage Alfresco's advanced ECM capabilities for managing, publishing and rendering any form of enterprise content (documents, digital assets, videos etc.) within Crafter apps.

There are two architectures that are possible to address this need.
Deploy content from Crafter Studio to a remote Crafter Engine (co-located with the remote app.) Then have the remote application request content and assets via service. This is a decoupled CMS architecture with a headless content delivery strategy.
Use the deployer to push content from the Studio into the remote application (disk, database, whatever you want.) The deployer has a simple Java interface that allows you to code actions that should be taken on a deployed changeset:
This is the full deployer API:
https://github.com/craftercms/deployer/tree/master/src/main/java/org/craftercms/deployer/api
This is the interface you would implement:
https://github.com/craftercms/deployer/blob/master/src/main/java/org/craftercms/deployer/api/DeploymentProcessor.java

Related

Xamarin.Forms app SQL-server database options

I've been studying Xamarin.Forms with goal of building cross-platform mobile app in VisualStudio2015. I've got a perfectly acceptable public facing web site but native app(s) are what the boss thinks we need.
The current web app hosted on IIS 7.5 uses a separate project(DLL) for database access to an on-premises SQL Server 2008 instance. This VStudio project exposes domain objects to the calling ASP.NET webforms by executing various stored procedures using System.Data.SqlClient.
I know building the mobile native app itself with Xamarin.Forms is one part of the challenge but I am asking here for clarification about how to approach the database requirements:
Do I need to create some sort of web service that provides the same CRUD functions required by my current web site?
Xamarin documentation lists several options for consuming web services and the more I search and read about data access I conclude that a callable web service of some type is going to be required for my eventual native mobile app.
Is this assumption correct?
Yes. You generally want a webservice layer brokering requests between your mobile app (or any remote client) and your DB server. If you already have all your crud operations in a separate library that is utilized by your website, then a webservice would just be another set of endpoints that rely on the same CRUD library.

How to show content published from Tridion 2011 in separate .net application

We have a standalone .net application, this application is nothing to do with Tridion implementation. But due to some strange suggestion from client we need to store some content (html fragment) in Tridion and publish it to broker, once this content is available in broker database we want to fetch it and show in .net application. Basically this content will a small block under right column e.g. like Login block (with user name password text box and some captions)
Is there any way to do it, also do we need to put storage config in .net applications config directory?
We are using Tridion 2011 SP1
The easiest way is to spin up the Tridion Content Delivery Web Service, which is based on OData, point it to your Tridion Database, and then grab the content from there from your other website.
I've written this article some time ago about how to get the web service up and running, it is focused on Java, but the steps are pretty similar for .NET. There is a prepackaged .NET web service you can just deploy on IIS, which then only needs the configuration part (cd_storage_conf.xml).
BTW - There is a Tridion-specific StackExchange site: http://tridion.stackexchange.com

How to use SharePoint only as a Content Management tool from a custom web application?

We have many custom built web applications (both external & internal) written in Classic ASP and ASP.NET 2.0 technologies. Internal users can upload files to these websites, which can then be viewed by External Users. In some cases, external users can upload documents as well.
Screenshot #1 gives a brief idea about the existing architecture.
Internal users upload documents to custom web applications. These documents are stored in a folder structure defined under the web application.
Meta data and user permissions like who can access the documents are stored in SQL Server database.
The same set of documents that are being uploaded to custom web applications also exist in SharePoint. However, the custom web applications are unaware of SharePoint. So, users have to download them from SharePoint and then Upload it to the custom web applications. We are currently using SharePoint 2010.
External users can also upload documents to the custom web applications. The meta data and user permissions of the document are saved into database based on the user who is uploading the document.
Screenshot #1:
Screenshot #2 shows the architecture that I am trying to achieve. I have done very little SharePoint development. Mostly, I have used the SharePoint web services to retrieve some list content but nothing more than that. Our future Custom Web Applications might be written using ASP.NET MVC. Please find the questions after the screenshot.
Screenshot #2:
Here are my questions:
I would like to have internal users continue to upload and maintain their documents in SharePoint. User security model is already defined in the SQL Server database. This security permissions should be available in the SharePoint document properties so users can choose who can view the document from the custom web applications. How can I achieve this? Should I have to copy the SQL Server user permissions info to SharePoint?
I believe that SharePoint Web Services or Business Connectivity Services (BCS) can help in retrieving the document and its related info from SharePoint. Which one of these would better suit this scenario?
Custom web app should display only the committed versions of the documents. If a user has checked out a document in SharePoint to make any changes, that checked out version of the document should not be visible to External users. Is that possible?
Has anyone tried this approach? Are there any pitfalls with this model? Are there any performance concerns with this design?
Will this design be of any hindrance if I rewrite our existing applications using ASP.NET MVC?
Is it possible to make use of SharePoint search feature within the custom web application (ASP.NET Web Forms / ASP.NET MVC)? In other words, can I send search criteria from custom web app and have SharePoint do the search and return the results back to custom web app?
I really appreciate your inputs.
Thanks in advance.
Question 1
Hard to say without having more details. So I'm going to assume that you currently use Active Directory for your authentication store. So this means that your SQL Server defines a list of roles and then has assigned memberships to these roles. I'm going to assume that your assigned membership is to AD users or groups. If this is true then I think your on the right path to push your permissions from SQL Server into SharePoint. SharePoint's API will accommodate what you need to do, however SharePoint has no built into mechanism for syncing your permission changes so that means you end up writing a whole lot of plumbing code. I would recommend that you research products that can handle the synchronization for you. Microsoft MIIS (I believe it is called Forefront Identity Management now) offer a set of architecture patterns that you should investigate.
Question 2
SharePoint Web Services or the SharePoint Client Access Services should work fine. I would highly recommend that use a proxy pattern to isolate your application from SharePoint calls (so you can isolate your application from SharePoint upgrades and potential content management server changes).
Question 3
Yes, that is possible. If you are using the publishing features of SharePoint Server (NOT SharePoint Foundation) you will have an easy way of identifying the current published version. Otherwise the service account you query with should be setup so it can only read published versions then SharePoint will automatically trim your query.
Question 4
I have not personally tried this design, but I really like the concept of creating a content management domain and then putting an abstract service layer on top of it. Will you have scale problems, depends on how you configure SharePoint and your applications. You can do it right or wrong. An depth answer between the two cannot be covered here. My one piece of advice is to make sure you plan for caching in your service interfaces (cache, cache, cache).
Question 5
Not if you implement it as a Service Layer. You would just use a repository pattern to call the service and return back entities for your model.
Question 6
Yes, Search is exposed via an API so it can be wrapped in a service layer too.
Good luck and feel free to contact me directly for more in depth discussion.

What is the best architecture for building a .NET website that may also support a native mobile app in the future?

I am in the planning phases of building a new ASP.NET website. The website is really a transactional web application where the users will log in and perform basic CRUD data operations. For right now this website will be accessible through a traditional desktop browser and a mobile browser. For the mobile browser we will build a separate scaled down version of the site.
In the future we may decide to create native mobile applications for Android or iOS devices also.
So the question I have is what is the best way to design the system to easily support that? Here is what I am thinking. I am thinking of building out 3 tiers to the site. The back end will be the database - SQL Server 2008. We will use stored procedures for all data access. The middle tier will be a web services tier. This tier will be built using RESTful web services and will contain all of the business logic. These web services will provide access to the database. The front end will be built using ASP.NET. The front end will only contain presentation logic. These tiers will actually be deployed on physically separate servers.
Then I am thinking that when we decide to build a native Android or iOS app that we could build those apps to simply call the same RESTful web services that the main site is calling.
Does this seem like a reasonable approach? The only thing I can think of is that the way we are building it right now the web services would be behind the firewall and would not be accessible to the outside world. When we want to support a native mobile app then we would need to make the web services accessible to the outside world.
Any thoughts? Does this seem like a good approach for building a high availability, high usage web app that needs to support native mobile apps in the future?
Thanks,
Corey
I'm with Rober Harvey there. With ASP.NET MVC you can make the presentation site in no time, use as Models your web service; with the link that he gave you, set the site for mobile browsing, and use the web services for the mobile apps when you build them.
For me it looks like a good plan. Regarding the web services being public, you can protect yourself by implementing API keys in the web service, so only your apps can use it.

Implementing document management with an ASP.NET MVC front-end

I've implemented a website for a client that holds editable articles.
I used ASP.NET MVC and made the content manageable by storing it in a 'Content' table in the database and creating a simple Admin section of the site, where the user can add/edit/remove content and choose where on the site it will appear.
Now the client has come back wanting full document management features. They want version control, permissions, PDF export and simple workflow on all content items.
I'm debating in my head how to do this.
I found one question where a lot of people recommended WSS (Windows Sharepoint Services).
The thing is, I want to build the admin interface myself and make it really easy for the client to use.
Will WSS allow me to do this?
WSS has functionality for storing and versioning of documents, and workflow.
I don't think that PDF conversion is not part of WSS, but you could use a 3rd party tool.
You could use the WSS UI for the Admin site, placing documents in spesific document libraries. But for your ASP.NET MVC site you could access WSS via web services (WCF).

Resources