Global liferay configuration (2)

Source: Internet
Author: User
Document directory
  • I. Custom Fields
  • 2. Monitoring)
  • Iii. Plug-in configuration
  • 4. Page Template
  • 5. website template
  • Vi. Server Management
  • VII. Portal instances
  • 8. Plug-in Installation
  • IX. Summary

I. Custom Fields

Custom fields are a method of adding attributes to many types of sets in a portal. For example, if you use liferay to create a book rating site, you can add custom fields to many collections in the portal. For example, you can add favorite books (favorite books) to the user object) field. If you use wiki to evaluate books, you can add custom fields such as book title and book author.

Adding custom fields is very simple. Click custom fields in the control panel, click Edit, and select Add Custom field.

Add the Custom Field key here. The key will be used as the field tag in the form. For some portal sets (such as users), the Custom field is an independent part in the form. In addition, custom fields and default fields are integrated into a form. Developers can access custom fields through <liferay-UI: custom-attribute/>.

You can create multiple types of fields: text fields (index or confidential), integers (integer), selection of multiple values (multiple menu options), and so on. After a field is created, its type cannot be changed.

2. Monitoring)

The next link on the left of the control panel is monitoring. With this function, you can see all the active sessions of the portal ). For performance considerations, this feature is usually disabled in the product. However, if this feature is enabled, you can see all active sessions here.

Iii. Plug-in configuration

The plugins configuration Link contains three types of plug-in labels: portlets, themes (themes), and layouts (layout). With these labels, you can see that those roles have permissions to add plug-ins to the page, you can also set the active or inactive status of the plug-in.

Note that this is only the basic configuration: If you want to query the permission configuration of a given Portlet or modify the permission configuration of an existing role, you can perform this operation again, however, if you need to add the permissions for the given Portlet to a new role, use the actions → define Permissions button in the role section of the control panel.

4. Page Template

The page templates link allows you to create a reusable template page that contains the required layout, Portlet, and web content. You can also edit an existing template or modify the permission.

Add a page template, select Add, enter the Template Name and description, and confirm the activity or activity of the template under the description field. Then, click the following link to edit the template. The template shown in is a page for returning students to college portal. Click the open Page Template link to open the manage pages interface, which is described in the next chapter.

After adding content, layout, and portlets to the page, return to the page template Portlet (another tab in the browser) and click Save.

It is easy to create a new page by using a template in the site. Navigate to Control Panel> pages. When you add a page, the newly created template will appear in the template drop-down menu.

5. website template

The site templates link allows you to define a set of predefined pages that can be used when new sites are created for an organization or community. You can define and edit a website template and its permissions.

Add a site template, click the site template link in the control panel, select Add, enter the Template Name and description, and set the template to active or inactive under the description.

Click actions> Manage pages to add a page to the template, and export the. Lar template file by managing the display of theme and CSS file configurations. You can also import a. Lar template file here.

On the page created for the template, you can add the desired porlet and content. After that, you can use these templates when creating a new community. When you add a community, a drop-down menu of the template will appear.

Vi. Server Management

The server administration link allows you to manage multiple tasks on the entire Portal Server. In contrast to the portal resource management, you can click this link to see a large amount of information clearly: now you can see a chart showing the currently available JVM resources.

(1) Resources)

The first tab is resources, which covers the charts mentioned above and many server-level operations that can be performed by management, including the following:

Garbage Collection: Send a garbage collection request to JVM.

Clearing VM caches: sends a single VM cache clearing request to the JVM.

Clearing caches implements ss the cluster: sends a request to the JVM to clear the content cache of the entire cluster.

Clearing database caches: sends a request to the JVM to clear the database cache.

Reindex all search indexes: Send and regenerate all search index requests. If you do not use the SOLR search server (See Chapter 7 for more information), this will greatly affect the portal performance. Therefore, do not execute it easily unless there is no user access time.

Generate thread dump: If you run the test, you can generate a thread dump file to check whether there is a deadlock or where there may be a deadlock.

Verify database tables of all plugins: Check that all database tables correspond to their indexes accurately.

(2) Log Level

Here, the log level can be dynamically modified for classes at any level in the portal. If your custom code has been deployed but is not in the list, you can use add category to add it. If you modify the top-level Log Level of the class level (for example, Com. liferay), all the class log levels inherited from this level are also changed. If you test specific items, the more clearly the class level, the better the level to modify the log level. If the hierarchy of the modified class is too high, a lot of unnecessary information will be generated.

(3) Performance

Liferay and JVM contain many settings defined in the property file. There are two labels: a real-world system attribute and a display portal attribute.

System Properties displays the detailed list of JVM and liferay system properties. This information can be used in debugging or checking the settings of the currently running portal.

Portal properties displays a detailed list of portal properties, which can be customized and described in the next chapter. If you want to check the current value of a property, you can view it without closing the portal or opening any property file.

(4) Verification Code

By default, liferay provides a simple verification code service that prevents malicious registration. You can also use Google's reCAPTCHA service to replace the default Verification Code Service.

The setting is simple. Enable reCAPTCHA, enter your public and private keys in the provided text box, and click Save. In this case, liferay uses reCAPTCHA instead of a simple verification code.

(5) data migration

If you are upgrading the liferay version or want to integrate two system data, this section describes how to complete the upgrade or data migration without writing any custom code.

In the first part, you can copy the entire liferay database from the currently running database to the specified database field set. Enter the driver name (the driver must be in the liferay classpath), copy the jdbc url of the database, and obtain the user name and password for accessing the database. after entering the name, click execute to copy the data.

The next part of the implementation of document integration, if you want to leave the Jackrabbit JSR-170 repository to the file system, or from the file system to form a jackrabbit JSR-170 repository, or form a repository supported by other document libraries, this is very simple. Make sure that the appropriate Hook has been established in the portal-ext.properties before the merge operation ). Select the document library hook that represents document integration and click execute. Your documents will be integrated into the new repository, at which point you can close liferay, change the default to the new repository in the portal-ext.properties, and run liferay.

You can integrate images from the image library in the same way.

(6) File Upload

Since liferay allows users to upload files in many places, you may need to limit the type and size of the files uploaded by users. Here, you can set the maximum size of the files that can be uploaded globally and overwrite the settings for specific applications. You can also restrict the extension of files that can be uploaded. These can be set flexibly.

(7) email

You can also configure the mail server here, as opposed to configuring mail with portal-ext.properties in the previous section. If the portal accepts emails (view the message boards Portlet in chapter 5), you can connect to a POP mail server. Of course, the portal should also be able to send emails (send notifications to users). You can connect to an SMTP server, which is strongly recommended.

Note that if you add the mail server settings here, the settings in the portal-ext.properties will be overwritten.

(8) OpenOffice

Liferay provides multiple formats for creating content: Web content (web content), images (images), and files (Files). These are all implemented through the Content Management System. Sometimes, it is very useful to convert content in whatever format into a content that is very convenient for users to browse. The liferay portal allows users to achieve this by integrating OpenOffice.org.

OpenOffice.org is an open-source office suite. It usually creates documents in Gui mode, but OpenOffice can run in "server" mode. When running in server mode, openOffice.org can be used to convert files of the supported types. Liferay can be used to automatically convert content online.

Use this label to tell liferay how to connect to a running OpenOffice.org instance. You can install OpenOffice.org and liferay on the same server. After installation, run the following command to start the server mode of OpenOffice.org:

Soffice-Headless-accept = "socket, host = 127.0.0.1, Port = 8100; URP ;"

-Nofirststartwizard

As you can see, the above command line specifies that OpenOffice.org runs on port 8100, which is the default port in the control panel. To use this port, you only need to check the Enable box to integrate liferay with OpenOffice.org.

If other content already occupies port 8100, find an idle port, change the corresponding port in the command line and control panel, and click Save.

(9) script

Liferay contains a step-by-step Console where administrators can execute migration or management task code. Supports many footfall languages, including JavaScript, groovy, Python, Ruby, and beanshell. For more details, see the liferay API documentation, http://wiki.liferay.com, or liferay in action.

(10) Close (shut down)

If you need to disable the liferay Portal Server when a user has logged on, you can use the shutdown label to notify the logged-on user portal to be closed soon. You can define the time when the portal will be closed, which will be displayed to logged-on users.

The user will see the duration you set at the top of their page. When the time expires, all the portal pages will display the portal has been shut down information. In this world, the server will be restarted and access will be restored.

VII. Portal instances

The liferay portal allows you to run multiple portal instances on a single server. The data of each portal instance is independent of each other. However, all portal data is stored in the same database.

Each portal requires a domain name. liferay directs users to access the portal using the domain name of each portal instance. Therefore, before configuring an instance, first configure the Domain Name of the instance on the network. If you have prepared these items, click the Add button here. There are three fields:

Web ID: usually the same as the domain name, indicating the User-Generated ID of the instance.

Virtual Host: Enter the domain name you configured on the network. When you use this domain name to access the liferay server, liferay can send them to the appropriate portal instance.

Mail domain: Enter the mail host used by the portal instance. Liferay will use this email host to send email notifications.

After entering the form, click Save to open it with a new domain name in the browser. You can see a liferay with the same clean installation. The new portal instance can be configured according to your needs.

8. Plug-in Installation

Open the Plugins installation link and you will see all the plug-ins that are currently installed. The following labels are available: portlets, themes, layout templates, hook plugins, and Web plugins. To install a new plug-in, click the install more portlets button to open the liferay plugin installer. Here, you can browse the liferay portlets library or install your own Portlet, the plugin installation is described in Chapter 6th.

IX. Summary

This chapter describes the resources related to the basic configuration of your site in the liferay portal, and describes how to use the liferay user interface to navigate to the portal, we also learned about the entire portal architecture and how to use liferay to design websites.

Next, we learned how to manage users, organizations, user groups, and roles using the control panel. We also learned about related server configurations, such as authentication, LDAP integration, and single-point logon. We also learned how to configure the user groups, communities, and roles associated with default users. At the same time, we also see how to set the reserved nickname and email address.

Next, we will see how to view and configure the settings of the entire server, how to view the memory usage of the current server, execute garbage collection, thread dump, and re-generate search indexes, clear cache and other content. I learned how to debug some content in the portal by modifying the Log Level and viewing the familiarity defined in the portal.

Finally, we learned how to notify users when liferay is disabled and how to enable OpenOffice.org integration, run multiple portal instances on a single portal server, and view the currently installed plug-ins.

All this information is designed to make you an experienced liferay administrator.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.