activejob-google_cloud_pubsub | Google Cloud Pub/Sub adapter and worker for ActiveJob | GCP library

 by   ursm Ruby Version: v0.7.1 License: MIT

kandi X-RAY | activejob-google_cloud_pubsub Summary

kandi X-RAY | activejob-google_cloud_pubsub Summary

activejob-google_cloud_pubsub is a Ruby library typically used in Cloud, GCP, Ruby On Rails applications. activejob-google_cloud_pubsub has no bugs, it has no vulnerabilities, it has a Permissive License and it has low support. You can download it from GitHub.

Google Cloud Pub/Sub adapter and worker for ActiveJob
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              activejob-google_cloud_pubsub has a low active ecosystem.
              It has 44 star(s) with 22 fork(s). There are 2 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 2 open issues and 4 have been closed. On average issues are closed in 210 days. There are 2 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of activejob-google_cloud_pubsub is v0.7.1

            kandi-Quality Quality

              activejob-google_cloud_pubsub has 0 bugs and 0 code smells.

            kandi-Security Security

              activejob-google_cloud_pubsub has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              activejob-google_cloud_pubsub code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              activejob-google_cloud_pubsub is licensed under the MIT License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              activejob-google_cloud_pubsub releases are available to install and integrate.
              Installation instructions are not available. Examples and code snippets are available.
              activejob-google_cloud_pubsub saves you 96 person hours of effort in developing the same functionality from scratch.
              It has 245 lines of code, 16 functions and 7 files.
              It has medium code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of activejob-google_cloud_pubsub
            Get all kandi verified functions for this library.

            activejob-google_cloud_pubsub Key Features

            No Key Features are available at this moment for activejob-google_cloud_pubsub.

            activejob-google_cloud_pubsub Examples and Code Snippets

            ActiveJob::GoogleCloudPubsub,Usage
            Rubydot img1Lines of Code : 18dot img1License : Permissive (MIT)
            copy iconCopy
            Rails.application.config.active_job.queue_adapter = :google_cloud_pubsub
            
            class HelloJob < ApplicationJob
              def perform(name)
                puts "hello, #{name}!"
              end
            end
            
            class HelloController < ApplicationController
              def say
                HelloJob.perform_lat  
            ActiveJob::GoogleCloudPubsub,Configuration,Adapter
            Rubydot img2Lines of Code : 9dot img2License : Permissive (MIT)
            copy iconCopy
            Rails.application.config.active_job.queue_adapter = ActiveJob::GoogleCloudPubsub::Adapter.new(
              async:  false,
              logger: Rails.logger,
            
              pubsub: Google::Cloud::Pubsub.new(
                project_id:  'MY-PROJECT-ID',
                credentials: 'path/to/keyfile.json'
                
            ActiveJob::GoogleCloudPubsub,Installation
            Rubydot img3Lines of Code : 1dot img3License : Permissive (MIT)
            copy iconCopy
            gem 'activejob-google_cloud_pubsub'
              

            Community Discussions

            Trending Discussions on activejob-google_cloud_pubsub

            QUESTION

            How to scale activejob-google_cloud_pubsub worker?
            Asked 2020-Jan-30 at 18:19
            Overview

            I have a Rails ActiveJob that uses the gem activejob-google_cloud_pubsub. (Short usage tutorial). My application is deployed to AppEngine on a ruby flex environment. While my application works as expected, I am having difficulty scaling the worker services that consume the messages from Google Cloud PubSub. The gem's README docs mention a way to specify a Worker's max_threads from the terminal but not from within the rails app. As I am reading the gem's source code I see the initialize for the worker takes in that variable max_threads (which default to the number of cores). The problem is that I don't see how to initialize the worker with a default configuration so I can increase the thread number.

            Questions Summary:

            1 - How to initialize the activejob-google_cloud_pubsub Worker with a higher number of threads?

            2 - Would it be unadvisable to initialize the worker with more threads than processors in the machine?

            Other Details:
            • I am deploying the worker on a separate service from the Rails Server by using a worker.yaml apart from the app.yaml
            • The worker service is being scaled manually to 3 instances, still this are barely handling 10 messages per second (lean message processor, only log to output and return)

            Any Input into how I can scale this type of queue processing would be helpful.

            ...

            ANSWER

            Answered 2020-Jan-30 at 18:19

            1 - How to initialize the activejob-google_cloud_pubsub Worker with a higher number of threads?

            worker.yaml

            Add the terminal flag --max_threads as described in the gem's README

            Source https://stackoverflow.com/questions/59913513

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install activejob-google_cloud_pubsub

            You can download it from GitHub.
            On a UNIX-like operating system, using your system’s package manager is easiest. However, the packaged Ruby version may not be the newest one. There is also an installer for Windows. Managers help you to switch between multiple Ruby versions on your system. Installers can be used to install a specific or multiple Ruby versions. Please refer ruby-lang.org for more information.

            Support

            Bug reports and pull requests are welcome on GitHub at https://github.com/ursm/activejob-google_cloud_pubsub.
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/ursm/activejob-google_cloud_pubsub.git

          • CLI

            gh repo clone ursm/activejob-google_cloud_pubsub

          • sshUrl

            git@github.com:ursm/activejob-google_cloud_pubsub.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular GCP Libraries

            microservices-demo

            by GoogleCloudPlatform

            awesome-kubernetes

            by ramitsurana

            go-cloud

            by google

            infracost

            by infracost

            python-docs-samples

            by GoogleCloudPlatform

            Try Top Libraries by ursm

            warden-openid

            by ursmRuby

            mongoblog

            by ursmRuby

            osm

            by ursmGo