Perspective API integrates Google perspective.
Development has started recently and an API key is requested for testing so unfortunately there is nothing to show here yet.
One of the problems with Drupal distributions is that they, by nature, contain an installation profile — and Drupal sites can only have one profile. That means that consumers of a distribution give up the ability to easily customize the out of the box experience.
This was fine when profiles were first conceived. The original goal was to provide “ready-made downloadable packages with their own focus and vision”. The out of the box experience was customized by the profile, and then the app was built on top of that starting point. But customizing the out of the box experience is no longer reserved for those of us that create distributions for others to use as a starting point. It’s become a critical part of testing and continuous integration. Everyone involved in a project, including the CI server, needs a way to reliably and quickly build the application from a single command. Predictably, developers have looked to the installation profile to handle this.
This practice has become so ubiquitous, that I recently saw a senior architect refer to it as “the normal Drupal paradigm of each project having their own install profile”. Clearly, if distributions want to be a part of the modern Drupal landscape, they need to solve the problem of profiles.Old Approach
In July 2016, Lightning introduced lightning.extend.yml which enabled site builders to:
- Install additional modules after Lightning had finished its installation
- Exclude certain Lightning components
- Redirect users to a custom URL upon completion
This worked quite well. It gave site builders the ability to fully customize the out of the box experience via contrib modules, custom code, and configuration. It even allowed them to present users with a custom “Installation Done” page if they chose — giving the illusion of a custom install profile.
But it didn’t allow developers to take full control over the install process and screens. It didn’t allow them to organize their code they way they would like. And it didn’t follow the “normal Drupal paradigm” of having an installation profile for each project.New Approach
After much debate, the Lightning team has decided to embrace the concept of “inheriting” profiles. AKA sub-profiles. (/throws confetti)
This is not a new idea and we owe a huge thanks to those that have contributed to the current patch and kept the issue alive for over five years. Nor is it a done deal. It still needs to get committed which, at this point, means Drupal 8.4.x.
On a technical level, this means that — similar to sub-themes — you can place the following in your own installation profile’s *.info.yml file and immediately start building a distribution (or simply a profile) on top of Lightning:base profile: name: lightning
To encourage developers to use this method, we will also be including a DrupalConsole command that interactively helps you construct a sub-profile and a script which will convert your old lightning.extend.yml file to the equivalent sub-profile.
This change will require some rearchitecting of Lightning itself. Mainly to remove the custom extension selection logic we had implements and replace it with standard dependencies.
This is all currently planned for the 2.0.5 release of lightning which is due out in mid March. Stay tuned for updates.
Another day, another Acquia Developer Certification exam review (see the previous one: Certified Back end Specialist - Drupal 8, I recently took the Front End Specialist – Drupal 8 Exam, so I'll post some brief thoughts on the exam below.
Drupal core announcements: 8.3.0 release candidate phase begins week of February 27; no Drupal 8.2.x or 7.x patch release planned
The release candidate phase for the 8.3.0 minor release begins the week of February 27. Starting that week, the 8.3.x branch will be subject to release candidate restrictions, with only critical fixes and certain other limited changes allowed.
8.3.x includes new experimental modules for workflows, layout discovery and field layouts; raises stability of the BigPipe module to stable and the Migrate module to beta; and includes several REST, content moderation, authoring experience, performance, and testing improvements among other things. You can read a detailed list of improvements in the announcements of alpha1 and beta1.
Minor versions may include changes to user interfaces, translatable strings, themes, internal APIs like render arrays and controllers, etc. (See the Drupal 8 backwards compatibility and internal API policy for details.) Developers and site owners should test the release candidate to prepare for these changes.
8.4.x will remain open for new development during the 8.3.x release candidate phase.
Drupal 8.3.0 will be released on April 5th, 2017.No Drupal 8.2.x or 7.x releases planned
March 1 is also a monthly core patch (bug fix) release window for Drupal 8 and 7, but no patch release is planned. This is also the final bug fix release window for 8.2.x (meaning 8.2.x will not receive further development or support aside from its final security release window on March 15). Sites should plan to update to Drupal 8.3.0 on April 5.
Sports League module is an out of the box solution to manage sports league functionality in Drupal. It relies on popular modules in drupal to help manage content typically used in websites for sports clubs. Main example is derived from football clubs, but can be easily extended.
- Manage competitions, multi competition editions and its standings.
- Manage clubs and teams.
- Manage matches, rosters and match moments.
- Manage players.
- Manage automatic statistics on players and teams.
- Manage club titles.
In this blog I want to explain the round up we have done around the refactoring of the acl_contact_cache. In the previous sprints we discovered that a lot of the performance was slowed down by the way the acl_contact_cache was used (or rather not used at all). See also the previous blog post: https://civicrm.org/blog/jaapjansma/the-quest-for-performance-improvements-5th-sprint
At the socialist party they have 350.000 contacts and around 300 users who can access civicrm. Most of the users are only allowed to see only the members in their local chapter.
In the previous blog we explained the proof of concept. We now have implemented this proof of concept and the average performance increase was 60%.
We created a table which holds which user has access to which contacts. We then fill this table once in a few hours. See also issue CRM-19934 for the technical implementation of this proof of concept.Performance increase in the search query
In the next examples we are logged in as a local member who can only see members in the chapter Amersfoort. We then search for persons with the name 'Jan'. And we measure how long the query for searching takes.
The query for presenting the list with letters in the search result looks likeSELECT count(DISTINCT contact_a.id) as rowCount FROM civicrm_contact contact_a LEFT JOIN civicrm_value_geostelsel geostelsel ON contact_a.id = geostelsel.entity_id LEFT JOIN civicrm_membership membership_access ON contact_a.id = membership_access.contact_id WHERE ((((contact_a.sort_name LIKE '%jan%')))) AND (contact_a.id = 803832 OR (((( ( geostelsel.`afdeling` = 806816 OR geostelsel.`regio` = 806816 OR geostelsel.`provincie` = 806816 ) AND ( membership_access.membership_type_id IN (1, 2, 3) AND ( membership_access.status_id IN (1, 2, 3) OR (membership_access.status_id = '7' AND (membership_access.end_date >= NOW() - INTERVAL 3 MONTH)) ) ) ) OR contact_a.id = 806816 )) AND (contact_a.is_deleted = 0) )) ORDER BY UPPER(LEFT(contact_a.sort_name, 1)) asc;
As you can see that is quite a complicated query and includes details about which members the user is allowed to see. Only executing this query takes around 0.435 seconds and the reason is that mysql has to check each record in civicrm_contact (which in this case is around 350.000 and growing)
After refactoring the acl cache functionality in CiviCRM Core the query looks different:SELECT DISTINCT UPPER(LEFT(contact_a.sort_name, 1)) as sort_name FROM civicrm_contact contact_a INNER JOIN `civicrm_acl_contacts` `civicrm_acl_contacts` ON `civicrm_acl_contacts`.`contact_id` = `contact_a`.`id` WHERE (((( contact_a.sort_name LIKE '%jan%' )))) AND `civicrm_acl_contacts`.`operation_type` = '2' AND `civicrm_acl_contacts`.`user_id` = '803832' AND `civicrm_acl_contacts`.`domain_id` = '1' AND (contact_a.is_deleted = 0) ORDER BY UPPER(LEFT(contact_a.sort_name, 1)) asc
The query now takes around 0,022 seconds to run (20 times faster).Explanation
How does this new functionality works:
1. Every time an ACL restriction is needed in a query civicrm core only does an inner join on the civicrm_acl_contacts table and that is all
2. The inner join is generated in the service 'acl_contact_cache' that service also checks whether the the civicrm_acl_contacts table need to be updated or not.
3. When an update of civicrm_acl_contacts table is needed depends on the settings under administer --> System Settings --> Misc --> ACL Contact Cache Validity (in minutes)
So how does this look like in code?
Below an example of how you could use the acl_contact_cache service to inject acl logic into your query:// First get the service from the Civi Container $aclContactCache = \Civi::service('acl_contact_cache'); // The $aclContactCache is a class based on \Civi\ACL\ContactCacheInterface // Now get the aclWhere and aclFrom part for our query $aclWhere = $aclContactCache->getAclWhereClause(CRM_Core_Permission::VIEW, 'contact_a'); $aclFrom = $aclContactCache->getAclJoin(CRM_Core_Permission::VIEW, 'contact_a'); // Now build our query $sql = "SELECT contact_a.* FROM civicrm_contact contact_a ".$aclFrom." WHERE 1 AND ".$aclWhere; // That is it now execute our query and handle the output...
The reason we use a service in the Civi Container class is that it is now also quite easy to override this part of core in your own extension.
The \Civi\ACL\ContactCache class has all the logic to for building the ACL queries. Meaning that this class contains the logic to interact with the ACL settings in CiviCRM, with the permissioned relationship etc.. All those settings are taken into account when filling civicrm_acl_contacts table which is per user and per operation once in the three hours.
This Drupal 8 module is meant for the fairly common use case of displaying the current page's submenu items as rendered content entities (typically in the 'teaser' or similar view mode).
You can add Entity Submenu Blocks from the Block layout page and configure the view modes that should be used for different content entity types. By default only menu items for content entities are rendered, but there is an option to render other menu items as simple links too.
Provides protecting some entities from deletion if they are used in other entities.
If you want to create a web resource, or to implement certain improvements on an existing one, then you must find specialists who will make your ideas come true. It’s quite a challenging task. We offered our 10 tips for hiring a top web developer by mentioning qualities that must be possessed. However, in addition, there are different types of web developers, with different skills, duties and types of work. The objectives and the scale of your project require appropriate experts.Read more
Drupal 8 integrating with Traditional ECMs to enhance Enterprise Content Management Capabilities. Drupal 8 is a strong platform with it’s Strong Web Content Management System, has a role to Play in integrating with the existing Challengers/Traditional ECMs to enhance their Enterprise Content Management Capabilities.
A numerical field with enormous range, high precision, efficient storage and computational properties, and associated units property
This module will automatically send a email messages to users who have abandoned their Drupal Commerce carts.
On each cron run the module finds Drupal Commerce carts that have been abandoned (using configurable settings) and that the user has gone to the point in the checkout process to have entered their email address. Then the module will send an email message to the user(s) to remind them that they have a cart, or ask if they had an issue during checkout.
Email messages are fully customizable. Message limits and other options are configurable in the module settings.
When thinking about ways to measure your website’s effectiveness, you may also want to think about the metrics you use to gauge the success of the website in accomplishing your business goals. How else do you measure success?
Thirsty for Drupal knowledge? Want to dive deep into a topic and learn from the best in the field? Like to get hands-on with your learning material? We are excited to offer 10 full-day training classes at DrupalCon Baltimore that will turn you into a Drupal superhero. No matter if you are an absolute beginner or Drupal expert, our classes cover all experience levels.
Our community is made up of incredible members from across the globe who continue to grow the Drupal project and create communities. DrupalCon is a place where community leaders and key contributors come together to meet, learn, and collaborate. The Drupal Association's Grant and Scholarship Program makes attending possible for many community members who may not have been otherwise able to join us.
The Drupal Association Engineering Team delivers value to all who are using, building, and developing Drupal. The team is tasked with keeping Drupal.org and all of the 20 subsites and services up and running. Their work would not be possible without the community and the project would not thrive without close collaboration. This is why we are running a membership campaign all about the engineering team. These are a few of the recent projects where engineering team + community = win!
We now have a new system for Documentation. These are guides Drupal developers and users need to effectively build and use Drupal. The new system replaces the book outline structure with a guides system, where a collection of pages with their own menu are maintained by the people who volunteer to keep the guides updated, focused, and relevant. Three years of work from the engineering team and community collaborators paid off. Content strategy, design, user research, implementation, usability testing and migration have brought this project to life.
Pages include code 'call-outs' for point-version specific information or warnings.
Thanks to the collaborators: 46 have signed up to be guide maintainers, the Documentation Working Group members (batigolix, LeeHunter, ifrik, eojthebrave), to tvn, and the many community members who write the docs!Enabling Drupal contribution everywhere
Helping contributors is what we do best. Here are some recent highlights from the work we're doing to help the community:
Users now have better profiles to make into Drupal résumés.
Months of content strategy work resulted in a better communication plan, including improved user experience for newly registered users.
Organization pages have expanded in scope to encourage more participants than just Drupal service providers. The organization list, new layout making case studies and contributions stand out, and a more robust contribution credit system are all helping to bring more contributors to the Drupal ecosystem.
We're expanding the contribution credit system to include more types of contribution, and we'll keep working on improving the system with check-ins every 6 months.
We have a process for prioritizing community initiatives so we can still help contributors. Thanks to volunteers who have proposed and helped work on initiatives recently, we've supported the launch of the Drupal 8 User guide and the ongoing effort to bring Dreditor features into Drupal.org itself.
You can help sustain the work of the Drupal Association by joining as a member. Thank you!
PostUp Mail module provides a integration with PostUp.com service.
This module is only for developers.