CNR (software) - How IT Works

How It Works

CNR.com is built as a collection of services in what is commonly referred to as a service oriented architecture (SOA). The highly scalable architecture is built using the following JEE 5 technologies:

  • JavaServer Faces (JSF) with faceletts
  • JBoss Seam
  • EJB 3.x
  • MySQL
  • Hibernate with JBoss Cache
  • JBoss
  • Apache Maven

The following is a list of the major services and some descriptive information about each one.

Import service – The import service is responsible for importing package repositories, parsing the package metadata, and matching the packages to products using a complex heuristically based algorithm. The Import service supports any Debian based distribution. RPM based packages can be supported by the domain model with additional work specific to the RPM package metadata schema and release management practices. The import service has a 98% success rate matching packages to products with admin support tools for finding and correcting any problems quickly. This service is responsible for making CNR.com the largest software warehouse for desktop Linux.

Warehouse service – The warehouse service contains the web services APIs used by external clients to acquire access to and install products from CNR.com. The APIs are open to the public and are SOAP based. The APIs consist of the following:

  • partnerLightup – The partnerLightup API provides a UUID MachineID which represents the installation life of a client. The resulting MchaineID is required for other warehouse API requests. This API exists for the purpose of auditing the client usage for reporting back to the originating partner.
  • lightup – The lightup API is the same as the partnerLightup API with the exception that there is no build tracking number to record.
  • getOses – The getOses API is used to query the warehouse for a list of the supported operating systems. This list is needed when the client cannot properly identify the operating system it is running on and must ask the user to choose from a list of the supported operating systems.
  • getDistSnapIndex – The getDistSnapIndex API is used to query the server for the aggregate product information for the specified operating system. This API returns a URI for a payload that contains concise product information useful for searching, sorting and viewing in a client.
  • getDisstSnapIndexDelta – The getDisstSnapIndexDelta API is used to query the server for the aggregate updates and deletes for the product information store given for the specified operating system.
  • productActionRequest – The productActionRequest API is used to query the server for a download URL for a specific, single product. If the server cannot grant access to the product, a resolution URL will be returned to the client instead so that the request can be resolved and re-executed.
  • reportActionRequest – The reportActionRequest API is used to report on the execution of the productActionRequest. This data is used to audit the reportActionRequest API success and/or failure.
  • getProductIdsForPkgBins – The getProductIdsForPkgBins API is used for clients on initial configurations or after changing distributions to determine the products that are already installed on the machine. The client can determine all the binary packages currently installed on the system, and then using this API, can match these products against the products in the distribution snapshot.

The warehouse service also handles product requisite management. Product requisites are user access requirements that must be fulfilled before a user can gain install access to a product. The product requisites consist of the following:

  • Requires purchase
  • Requires EULA
  • Must purchase primary product first (used to secure dependencies)

Ecommerce service – The ecommerce service handles all purchases of commercial software, purchases of member services, and the collection of user acceptance of product EULAs for those products that require such. The ecommerce service is also responsible for handling the DRM requirements of software that have them, such as delivering activation codes to the user or account registration with ISVs.

User management – The user management service handles the creation and management of user accounts as well as the authentication and authorization of user accounts and user access respectively. Authentication is managed using LDAP and SSO is utilized via a token federation service.

Package management – The package management service handles the secure and non-secure storage of all the packages and provides for the secure delivery for all types of packages: free, non-free, and commercial, making CNR.com the industry leader for delivering desktop Linux software. This service is also responsible for the categorization of each product. The categories are an XDG base with an extended set of CNR categories not found in the XDG set intended to enhanced searchability.

Community service – The community service provides for the forum, wiki document and blogging features for both the community in general and for each product. Each product has its own mini-community where discussions and self help community support can thrive.

CNR.com service – This is the presentation layer of the CNR.com architecture and is responsible for providing the Web 2.0 interfaces. These interfaces allow for the following features:

  • Add/Review/Edit the long and brief description for any product
  • Add/Review/Edit the product logo and logo thumbnail
  • Add/Review/Edit product screenshots
  • Add/Review/Edit product ratings
  • Add/Review/Edit product reviews
  • Filter and sort content
  • Product specifications with instant access to source code and build files

Other interfaces include the product chart that has a refresh cycle of once per 10 minutes and various administrative interfaces for viewing and managing product and user data.

Support service – The support service provides for the tracking, managing and resolving of user submitted support issues. It also has a facility for paid support features versus free support features.

Mail lists service – The mail list service is responsible for the mailing list enrollment and subscription management as well as the sending of system emails to the user as a result of some user-based activity on the site.

Secure data – The secure data service is responsible for the secure storage of credit card profiles that the user has elected to save.

Category data – The category data service is responsible for the storage of the data associated with product categories.

Audit data – The audit data service is responsible for the storage of user activity records such as installs, client registration, machine registrations, etc.

Product data – The product data service is responsible for the storage of product specific data as well as the product aggregation data.

Warehouse data – The warehouse data service is responsible for the storage of package level data and distribution level data.

Resource data – The resource data service is responsible for the storage of all images associated with a product including user provided images like logos and screenshots.

CNR client – The CNR client is a desktop client application that interfaces with apt and dpkg on the desktop and with the warehouse web services on the server. It is intended to provide a starting point for the community to build its own variations of client software. The application is written in C++ with the GUI built on the QT framework. API integration is done through the gsoap framework. The CNR client is open source and open licensed so that anyone can use it for their own purposes without any need to license it. Features include:

  • Installing and Uninstalling software
  • Listing all software on the local machine
  • Product and OS level updates with messaging
  • Auto updating of itself
  • Distribution selector to enable installing from more than one distribution
  • Package detection for packages installed outside of the CNR system

Read more about this topic:  CNR (software)

Famous quotes containing the word works:

    The noble simplicity in the works of nature only too often originates in the noble shortsightedness of him who observes it.
    —G.C. (Georg Christoph)