• Project page: https://www.drupal.org/sandbox/karbunkul/2789769
  • Drupal core compatibility 8.x
  • Git clone: git clone --branch 8.x-1.x https://git.drupal.org/sandbox/karbunkul/2789769.git ra_client
  • Install dependency.
  • On page /ra/client you should be see example request.

Ra Framework client API for Drupal 8

Synopsis

Provides Ra Framework client API. More information about Ra Framework is here

Implementation emerap/ra_client library for Drupal 8.

ra.client.yml file

Create file [MODULE_NAME].ra.client.yml inside module directory.

YAML example.

source_id:
    path: 'http://emerap.com/ra/method'

Php example


use Drupal\ra_client\RaClient;

...

// \Drupal\ra_client\RaClient instance
$client = new RaClient('emerap');

// Get all available methods.
$methods = $client->query('ra.methods')->getRaw();
CommentFileSizeAuthor
Screen Shot 2016-08-25 at 15.00.18.png42.06 KBkarbunkul
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

karbunkul created an issue. See original summary.

PA robot’s picture

Multiple Applications
It appears that there have been multiple project applications opened under your username:

Project 1: https://www.drupal.org/node/2789885

Project 2: https://www.drupal.org/node/2788817

As successful completion of the project application process results in the applicant being granted the 'Create Full Projects' permission, there is no need to take multiple applications through the process. Once the first application has been successfully approved, then the applicant can promote other projects without review. Because of this, posting multiple applications is not necessary, and results in additional workload for reviewers ... which in turn results in longer wait times for everyone in the queue. With this in mind, your secondary applications have been marked as 'closed(duplicate)', with only one application left open (chosen at random).

If you prefer that we proceed through this review process with a different application than the one which was left open, then feel free to close the 'open' application as a duplicate, and re-open one of the project applications which had been closed.

I'm a robot and this is an automated message from Project Applications Scraper.

PA robot’s picture

We are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)

Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).

I'm a robot and this is an automated message from Project Applications Scraper.

bubu’s picture

Issue summary: View changes

Hi,
1. I added correct project page link to the summary.
2. I corrected git clone command. It was missing the folder name at the end: ra_client.
3. There are some issues with coding standards. Please see this: http://pareview.sh/pareview/httpsgitdrupalorgsandboxkarbunkul2789769git

ILE: /var/www/drupal-7-pareview/pareview_temp/README.md
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
31 | ERROR | [x] Expected 1 newline at end of file; 0 found
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
karbunkul’s picture

Thanks. I fixed issue.

vlad.dancer’s picture

Status: Needs review » Needs work

Automated Review

Review of the 8.x-1.x branch (commit 8ab8b18):

  • No automated test cases were found, did you consider writing Simpletests or PHPUnit tests? This is not a requirement but encouraged for professional software development.

This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.
See https://pareview.sh/node/1154

Manual Review

README.txt/README.md
[No: Does not follow] the guidelines for in-project documentation and/or the README Template.
Coding style & Drupal API usage
List of identified issues in no particular order. Use (*) and (+) to indicate an issue importance. Replace the text below by the issues themselves:
(*) Major finding, needs work
  1. Do a cleanup in the module:
    - remove composer.lock
    - remove .gitignore
  2. Don't assume that ra_client php package should live inside ra_client/vendor folder, because
    common way to load php packages in drupal via global drupal composer file
    (eg. DRUPAL_ROOT/composer.json or like drupal-projects locates it https://github.com/drupal-composer/drupal-project)
  3. Why do you use if (!file_exists(__DIR__ . '/vendor/autoload.php')) {
    instead of if (!class_exists('Emerap\RaClient\Client')) {
Just a recommendations
  1. use everywhere united style for array syntax: array() or []
  2. Why do this class Controller/RaClientTest.php contains word 'Test'. Is this class used to test module functionality?

The starred items (*) are fairly big issues and warrant going back to Needs Work. Items marked with a plus sign (+) are important and should be addressed before a stable project release. The rest of the comments in the code walkthrough are recommendations.

If added, please don't remove the security tag, we keep that for statistics and to show examples of security problems.

This review uses the Project Application Review Template.

Personal opinion

All of the author's modules designed for developers (ra, ra_client, telegram_bot, etc..),
but great api/services stars with excellent documentation. Please add more examples,
fix readme files. Also make RA documentation more rich on the githab and describe
more clearly RA purpose, examples: (http://www.fluxkraft.com/, https://www.drupal.org/node/2057959)

PA robot’s picture

Status: Needs work » Closed (won't fix)

Closing due to lack of activity. If you are still working on this application, you should fix all known problems and then set the status to "Needs review". (See also the project application workflow).

I'm a robot and this is an automated message from Project Applications Scraper.