GithubHelp home page GithubHelp logo

aws-sdk-php-symfony's Introduction

AWS Service Provider for Symfony

Latest Stable Version Total Downloads

A Symfony bundle for including the AWS SDK for PHP.

Jump To:

Getting Started

Installation

The AWS bundle can be installed via Composer by requiring theaws/aws-sdk-php-symfony package in your project's composer.json:

{
    "require": {
        "aws/aws-sdk-php-symfony": "~2.0"
    }
}

and adding an instance of Aws\Symfony\AwsBundle to your application's kernel:

class AppKernel extends Kernel
{
    public function registerBundles()
    {
        return [
            ...
            new \Aws\Symfony\AwsBundle(),
        ];
    }
    ...
}

Configuration

By default, configuration is handled by the SDK rather than by the bundle, and no validation is performed at compile time. Full documentation of the configuration options available can be read in the SDK Guide.

If AWS_MERGE_CONFIG environment variable is set to true, configuration validation and merging are enabled. The bundle validates and merges known configuration options, including for each service. Additional configuration options can be included in a single configuration file, but merging will fail if non-standard options are specified in more than once.

To use a service for any configuration value, use @ followed by the service name, such as @a_service. This syntax will be converted to a service during container compilation. If you want to use a string literal that begins with @, you will need to escape it by adding another @ sign.

When using the SDK from an EC2 instance, you can write credentials: ~ to use instance profile credentials. This syntax means that temporary credentials will be automatically retrieved from the EC2 instance's metadata server. It's also the preferred technique for providing credentials to applications running on that specific context.

Sample configuration can be found in the tests/fixtures folder for YAML, PHP, and XML.

Sample YML Configuration

The sample configuration which can be placed in app/config/config.yml file.

framework:
    secret: "Rosebud was the name of his sled."

aws:
    version: latest
    region: us-east-1
    credentials:
        key: not-a-real-key
        secret: "@@not-a-real-secret" # this will be escaped as '@not-a-real-secret'
    DynamoDb:
        region: us-west-2
    S3:
        version: '2006-03-01'
    Sqs:
        credentials: "@a_service"
    CloudSearchDomain:
        endpoint: https://search-with-some-subdomain.us-east-1.cloudsearch.amazonaws.com

services:
    a_service:
        class: Aws\Credentials\Credentials
        arguments:
            - a-different-fake-key
            - a-different-fake-secret

Usage

This bundle exposes an instance of the Aws\Sdk object as well as instances of each AWS client object as services to your symfony application. They are name aws.{$namespace}, where $namespace is the namespace of the service client. For instance:

Service Instance Of
aws.dynamodb Aws\DynamoDb\DynamoDbClient
aws.ec2 Aws\Ec2\Ec2Client
aws.s3 Aws\S3\S3Client
aws_sdk Aws\Sdk

The services made available depends on which version of the SDK is installed. To view a full list, run the following command from your application's root directory:

php bin/console debug:container aws

Full documentation on each of the services listed can be found in the SDK API docs.

Getting Help

Please use these community resources for getting help. We use the GitHub issues for tracking bugs and feature requests and have limited bandwidth to address them.

This SDK implements AWS service APIs. For general issues regarding the AWS services and their limitations, you may also take a look at the Amazon Web Services Discussion Forums.

Opening Issues

If you encounter a bug with aws-sdk-php-symfony we would like to hear about it. Search the existing issues and try to make sure your problem doesn’t already exist before opening a new issue. It’s helpful if you include the version of aws-sdk-php-symfony, PHP version and OS you’re using. Please include a stack trace and reduced repro case when appropriate, too.

The GitHub issues are intended for bug reports and feature requests. For help and questions with using aws-sdk-php please make use of the resources listed in the Getting Help section. There are limited resources available for handling issues and by keeping the list of open issues lean we can respond in a timely manner.

Contributing

We work hard to provide a high-quality and useful SDK for our AWS services, and we greatly value feedback and contributions from our community. Please review our contributing guidelines before submitting any issues or pull requests to ensure we have all the necessary information to effectively respond to your bug report or contribution.

Resources

aws-sdk-php-symfony's People

Contributors

aws-sdk-php-automation avatar bits4breakfast avatar brianfreytag avatar chrisguitarguy avatar cjyclaire avatar clementtalleu avatar develth avatar diehlaws avatar extreme avatar greg0ire avatar howardlopez avatar hyandell avatar jeskew avatar joksnet avatar kellertk avatar kerihenare avatar khez avatar kstich avatar mpdude avatar orkin avatar piotrpasich avatar pzorn avatar samremis avatar somayab avatar spajxo avatar stobrien89 avatar sylvaindeloux avatar trandangtri avatar vincentlanglet avatar yenfryherrerafeliz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aws-sdk-php-symfony's Issues

Symfony 4.0.0 compatibility

(PHP7.2, symfony 4.0)

Trying to install but returns the follow error:

Your requirements could not be resolved to an installable set of packages.

Problem 1
- Conclusion: don't install symfony/dependency-injection v3.4.0
- Installation request for aws/aws-sdk-php-symfony ^1.3 -> satisfiable by aws/aws-sdk-php-symfony[1.3.0].
- Conclusion: remove symfony/console v4.0.0
- Installation request for symfony/dependency-injection (locked at v4.0.0) -> satisfiable by symfony/dependency-injection[v4.0.0].
- Conclusion: don't install symfony/console v4.0.0
- aws/aws-sdk-php-symfony 1.3.0 requires symfony/dependency-injection ~2.3|~3.0 -> satisfiable by symfony/dependency-injection[v2.3.0, v2.3.1, v2.3.10, v2.3.11, v2.3.12, v2.3.13, v2.3.14, v2.3.15, v2.3.16, v2.3.17, v2.3.18, v2.3.19, v2.3.2, v2.3.20, v2.3.21, v2.3.22, v2.3.23, v2.3.24, v2.3.25, v2.3.26, v2.3.27, v2.3.28, v2.3.29, v2.3.3, v2.3.30, v2.3.31, v2.3.32, v2.3.33, v2.3.34, v2.3.35, v2.3.36, v2.3.37, v2.3.38, v2.3.39, v2.3.4, v2.3.40, v2.3.41, v2.3.42, v2.3.5, v2.3.6, v2.3.7, v2.3.8, v2.3.9, v2.4.0, v2.4.1, v2.4.10, v2.4.2, v2.4.3, v2.4.4, v2.4.5, v2.4.6, v2.4.7, v2.4.8, v2.4.9, v2.5.0, v2.5.1, v2.5.10, v2.5.11, v2.5.12, v2.5.2, v2.5.3, v2.5.4, v2.5.5, v2.5.6, v2.5.7, v2.5.8, v2.5.9, v2.6.0, v2.6.1, v2.6.10, v2.6.11, v2.6.12, v2.6.13, v2.6.2, v2.6.3, v2.6.4, v2.6.5, v2.6.6, v2.6.7, v2.6.8, v2.6.9, v2.7.0, v2.7.1, v2.7.10, v2.7.11, v2.7.12, v2.7.13, v2.7.14, v2.7.15, v2.7.16, v2.7.17, v2.7.18, v2.7.19, v2.7.2, v2.7.20, v2.7.21, v2.7.22, v2.7.23, v2.7.24, v2.7.25, v2.7.26, v2.7.27, v2.7.28, v2.7.29, v2.7.3, v2.7.30, v2.7.31, v2.7.32, v2.7.33, v2.7.34, v2.7.35, v2.7.36, v2.7.37, v2.7.38, v2.7.4, v2.7.5, v2.7.6, v2.7.7, v2.7.8, v2.7.9, v2.8.0, v2.8.1, v2.8.10, v2.8.11, v2.8.12, v2.8.13, v2.8.14, v2.8.15, v2.8.16, v2.8.17, v2.8.18, v2.8.19, v2.8.2, v2.8.20, v2.8.21, v2.8.22, v2.8.23, v2.8.24, v2.8.25, v2.8.26, v2.8.27, v2.8.28, v2.8.29, v2.8.3, v2.8.30, v2.8.31, v2.8.4, v2.8.5, v2.8.6, v2.8.7, v2.8.8, v2.8.9, v3.0.0, v3.0.1, v3.0.2, v3.0.3, v3.0.4, v3.0.5, v3.0.6, v3.0.7, v3.0.8, v3.0.9, v3.1.0, v3.1.1, v3.1.10, v3.1.2, v3.1.3, v3.1.4, v3.1.5, v3.1.6, v3.1.7, v3.1.8, v3.1.9, v3.2.0, v3.2.1, v3.2.10, v3.2.11, v3.2.12, v3.2.13, v3.2.14, v3.2.2, v3.2.3, v3.2.4, v3.2.5, v3.2.6, v3.2.7, v3.2.8, v3.2.9, v3.3.0, v3.3.1, v3.3.10, v3.3.11, v3.3.12, v3.3.13, v3.3.2, v3.3.3, v3.3.4, v3.3.5, v3.3.6, v3.3.7, v3.3.8, v3.3.9, v3.4.0].

  • symfony/dependency-injection v2.3.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.11 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.12 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.13 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.14 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.15 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.16 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.17 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.18 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.19 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.20 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.21 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.22 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.23 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.24 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.25 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.26 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.27 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.28 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.29 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.30 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.31 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.32 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.33 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.34 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.35 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.36 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.37 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.38 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.39 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.40 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.41 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.42 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.3.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.4.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.11 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.12 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.5.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.11 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.12 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.13 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.6.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.11 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.12 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.13 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.14 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.15 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.16 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.17 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.18 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.19 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.20 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.21 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.22 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.23 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.24 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.25 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.26 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.27 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.28 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.29 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.30 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.31 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.32 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.33 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.34 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.35 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.36 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.37 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.38 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.7.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.11 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.12 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.13 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.14 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.15 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.16 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.17 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.18 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.19 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.20 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.21 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.22 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.23 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.24 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.25 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.26 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.27 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.28 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.29 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.30 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.31 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v2.8.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.0.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.1.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.11 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.12 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.13 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.14 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.2.9 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.0 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.1 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.10 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.11 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.12 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.13 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.2 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.3 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.4 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.5 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.6 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.7 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.8 conflicts with symfony/console[v4.0.0].
    • symfony/dependency-injection v3.3.9 conflicts with symfony/console[v4.0.0].
    • Installation request for symfony/console ^4.0 -> satisfiable by symfony/console[v4.0.0].

Installation failed, reverting ./composer.json to its original content.

Cannot read credentials from /Users/<myUser>/.aws/credentials

Hi all, I have placed my aws credentials in the .env.local file of my Symfony app but when I try to use the S3 client I get the error Cannot read credentials from /Users//.aws/credentials, which suggests to me that it's not finding my .env.local values, even though I have verified the env values are present by running ./bin/console debug:container --env-vars

Invalid token

I'm using aws-sdk-php-symfony on sf 3.4.4 everything worked fine until I had to point to another sqs account.

In the new account I have created the credentials and I have specified right region but I get this error:

Error executing "SendMessageBatch" on "https://sqs.eu-west-1.amazonaws.com/0000000000/queue";
 AWS HTTP error: Client error: `POST https://sqs.eu-west-1.amazonaws.com/0000000000/queue` resulted 
 in a `403 Forbidden` response:
<?xml version="1.0"?><ErrorResponse xmlns="http://queue.amazonaws.com/doc/2012-11-05/"><Error><Type>Sender</Type><Code>
I (truncated...)
 InvalidClientTokenId (client): The security token included in the request is invalid.
  - <?xml version="1.0"?><ErrorResponse xmlns="http://queue.amazonaws.com/doc/2012-11-05/">
  <Error><Type>Sender</Type><Code>InvalidClientTokenId</Code><Message>The security token included 
  in the request is invalid.</Message><Detail/></Error><RequestId>f476a7e3-b735-5ee2-ad8b-f4f364d4285a</RequestId>
  </ErrorResponse>

how do you use IAM roles

Describe the bug

In the readme it makes a quick reference to instance profiles & EC2's IMDS.

how do I use AWS environment variables to run Symfony as an AWS role?

is it still credentials: ~? is it unsupported?

Expected Behavior

I expect to be able to have the key and ID be blank and have the SDK work like every other AWS SDK.

Current Behavior

Cannot autowire service "App\Service\Aws": argument "$access_key" of method "__construct()" has no type-hint, you should configure its value explicitly.

Reproduction Steps

leave the AWS autowire/configuration sections blank.

Possible Solution

documentation updates, and a default method for when the config is blank to use the SDK's autoresolve.

Additional Information/Context

No response

SDK version used

3.187.3

Environment details (OS name and version, etc.)

Fedora Linux

Add Symfony 6 compability

Describe the bug

Method "Symfony\Component\Config\Definition\ConfigurationInterface::getConfigTreeBuilder()" might add "TreeBuilder" as a native return type declaration in the future. Do the same in implementation "Limenius\ReactBundle\DependencyInjection\Configuration" now to avoid errors or add an explicit @return annotation to suppress this message.

Expected Behavior

Always time

Current Behavior

show deprecation message

Reproduction Steps

upgrade you project for Symfony 5.4 / 6.0

Possible Solution

No response

Additional Information/Context

No response

SDK version used

2.5.0

Environment details (OS name and version, etc.)

MacOS

Custom S3 Client service throwing error

I'm attempting to create two S3 client services for my application. Each has different permissions as per the IAM roles the keys have.

I'm getting this error:

Type error: Argument 1 passed to Aws\\S3\\S3Client::__construct() must be of the type array, string given

This is the services.yml entry:

app.aws.read:
        class: '%aws.s3.class%'
        arguments: ['%aws_keys_read_key%', '%aws_keys_read_secret%']

I don't see why this shouldn't work since an array is being given as the argument.

How to pass parameters in SesClient

I have a difficulty passing the parameters to SesClient. At least that's what I believe given the error message. I tried countless configurations but I will forward only the one that seems correct to me.
composer show --installed:

aws/aws-sdk-php                          3.19.24 AWS SDK for PHP - Use Amazon Web Services in your PHP project
aws/aws-sdk-php-symfony                  1.2.0   A Symfony bundle for v3 of the AWS SDK for PHP
--- more ---

In my config.yml I have :

aws:
    key: myKey
    secret: topSecret
    region: eu-west-1
    version: latest

In my services.ymlI have:

services:
  aws.ses:
    class:  Aws\Ses\SesClient
    arguments:
        - [key, secret, region, version]

In my src/AppBundle/Controller/AwsController.php :

class AwsController extends Controller
{
    /**
     * @Route("/aws", name="aws")
     */
    public function awsAction()
    {
        $mailer = $this->get('aws.ses');
        return new Response ("");
    }
}

But I get this error:

Missing required client configuration options: 

region: (string)

A "region" configuration value is required for the "email" service
(e.g., "us-west-2"). A list of available public regions and endpoints can be
found at http://docs.aws.amazon.com/general/latest/gr/rande.html.

version: (string)

A "version" configuration value is required. Specifying a version constraint
ensures that your code will not be affected by a breaking change made to the
service. For example, when using Amazon S3, you can lock your API version to
"2006-03-01".

Your build of the SDK has the following version(s) of "email": * "2010-12-01"

You may provide "latest" to the "version" configuration value to utilize the
most recent available API version that your client's API provider can find.
Note: Using 'latest' in a production application is not recommended.

A list of available API versions can be found on each client's API documentation
page: http://docs.aws.amazon.com/aws-sdk-php/v3/api/index.html. If you are
unable to load a specific API version, then you may need to update your copy of
the SDK.

Any ideas on what am I missing?

deleteObject 403 Error

Hi,

I've got a problem, i trying to delete an image uploaded on my bucket with this code :

if (($oldImageName = $user->getUserInfo()->getImageName()) != "" && $this->s3->doesObjectExist('myBucket', $oldImageName)) {
            $this->s3->deleteObject([
                'Bucket' => 'myBucket',
                'Key' => $oldImageName
            ]);
}

But i receive a 403 Forbidden error. I succeed to upload images, fetch them but i can't delete them.
Do you know what's the problem ?

Thanks to the team !

Error using endpoint_provider

I'm trying to use "endpoint_provider" . I have defined a service and a static function

`
app\config\services.yml

services:

aws_s3.client:
class: Aws\S3\S3Client
factory_class: Aws\S3\S3Client
factory_method: 'factory'
arguments:
options:
region: %aws.region%
version: %aws.version%
base_url: %aws.base_url%
endpoint_provider: MyApp\PromoBundle\EndpointProvider::getEndPoint
credentials:
key: %aws.key%
secret: %aws.secret%`

`src\MyApp\PromoBundle\EndPointProvider.php

$params['region'] . '.example.com']; } } ` ` composer.json { "require": { ... "aws/aws-sdk-php-symfony": "~1.0" } }` When I try to run the app always I get the same error: > PHP Fatal error: Call to undefined function MyApp\PromoBundle\EndpointProvider::getEndPoint() in \vendor\aws\aws-sdk-php\src\Endpoint\EndpointProvider.php on line 60 Can help me? Regards

Issue with console lint:container

Version of AWS SDK for PHP?

aws/aws-sdk-php 3.133.40
aws/aws-sdk-php-symfony 2.2.1

Version of AWS Service Provider for Symfony?

?

Version of Symfony (bin/console --version in project dir)?

5.0.5

Version of PHP (php -v)?

7.4

What issue did you see?

Hello.

When ./bin/console lint:container Then Invalid service "doctrine.dbal.default_connection": method "Aws\Sdk::createRekognition()" does not exist..

Steps to reproduce

Having doctrine and launch ./bin/console lint:container

Additional context

Word Press | Missing required client configuration options : AWS PHP SDK 3.X

Hi There,

I have installed AWS PHP SDK 3.X in a Word Press container. SDK integration works fine.. But some of the core Word Press features are broken and i have following error in logs:

[07-Nov-2018 14:54:53 UTC] PHP Fatal error: Uncaught InvalidArgumentException: Missing required client configuration options:

version: (string)

A "version" configuration value is required. Specifying a version constraint
ensures that your code will not be affected by a breaking change made to the
service. For example, when using Amazon S3, you can lock your API version to
"2006-03-01".

Your build of the SDK has the following version(s) of "s3": * "2006-03-01"

Few observations :

  1. I'm consistently getting this error whenever i try to create a new page in WordPress Editor
  2. I'm getting an error for S3Client, but i'm not using any S3 Client.

Here is some other information:

  1. Word Press Version - 4.9.8
  2. PHP Version - 7+

Please take a look and share your thoughts.

Thanks,
Ashwini

SDK not retrieving the instance role

Describe the bug

After deploying my project on Elastic Beanstalk I get 403 errors when I query AWS APIs.

Expected Behavior

The SDK should automatically retrieve the instance role to query the APIs.

Current Behavior

Nothing really to add here except the details of one of the 403 errors I got. I tried on 2 different projects and has the same issue on SQS for one and S3 for the other.

Error executing "SendMessage" on "https://sqs.us-west-2.amazonaws.com/queueid/queuename.fifo"; AWS HTTP error: Client error: `POST https://sqs.us-west-2.amazonaws.com/queueid/queuename.fifo` resulted in a `403 Forbidden` response:
<?xml version="1.0"?><ErrorResponse xmlns="http://queue.amazonaws.com/doc/2012-11-05/"><Error><Type>Sender</Type><Code>I (truncated...)
 InvalidClientTokenId (client): The security token included in the request is invalid. - <?xml version="1.0"?><ErrorResponse xmlns="http://queue.amazonaws.com/doc/2012-11-05/"><Error><Type>Sender</Type><Code>InvalidClientTokenId</Code><Message>The security token included in the request is invalid.</Message><Detail/></Error><RequestId>0a31250d-a333-5d1a-8bd1-7fc295b8cf1a</RequestId></ErrorResponse>

AWS support asked me to try calling GetCallerIdentity but I got a 403 error as well :

Error executing "GetCallerIdentity" on "https://sts.amazonaws.com"; AWS HTTP error: Client error: `POST https://sts.amazonaws.com` resulted in a `403 Forbidden` response:
<ErrorResponse xmlns="https://sts.amazonaws.com/doc/2011-06-15/">
  <Error>
    <Type>Sender</Type>
    <Code>InvalidCli (truncated...)
 InvalidClientTokenId (client): The security token included in the request is invalid. - <ErrorResponse xmlns="https://sts.amazonaws.com/doc/2011-06-15/">
  <Error>
    <Type>Sender</Type>
    <Code>InvalidClientTokenId</Code>
    <Message>The security token included in the request is invalid.</Message>
  </Error>
  <RequestId>91db51b4-a836-44f4-9532-bbba0c76cbef</RequestId>
</ErrorResponse>

I did not specify any configuration related to retrieving the instance role since it does not seem to be required and it was working perfectly fine before (amazon linux 1 on elastic beanstalk or previous version of AL2, I'm not too sure unfortunately)

Reproduction Steps

Create a Symfony project, install this bundle and write some code to call an API.
Deploy to Elastic Beanstalk and add a role with required access for the chosen API.
Open the URL to execute the code and see the error.

Possible Solution

I added AWS_KEY and AWS_SECRET manually as environment variables on the Elastic Beanstalk console.

Additional Information/Context

No response

SDK version used

3.218.5

Environment details (OS name and version, etc.)

PHP 8.0 running on 64bit Amazon Linux 2/3.3.12

Cache client credentials

Please fill out the sections below to help us address your issue.

Version of AWS SDK for PHP?

aws/aws-sdk-php 3.133.26

Version of AWS Service Provider for Symfony?

aws/aws-sdk-php-symfony 1.3.0

Version of Symfony (bin/console --version in project dir)?

Symfony 3.4.38

Version of PHP (php -v)?

PHP 7.3.13

What issue did you see?

Unable to configure the cache for the client credentials

Steps to reproduce

N/A

Additional context

I'm trying to configure caching the client credentials using the DoctrineCacheAdaptor, but I am unable to get the cache to be used. All requests are still accessing the credentials each time the command is run.

(We swap credential providers on production, thus why we have 2 different configurations, but neither are using the cache.)

// config.yml
aws:
    version: latest
    region: ap-southeast-2
    credentials: "@aws_credentials"
    sqs:
        credentials: "@aws_cache_credentials"
//services.yml
    aws_cache_credentials:
        class: Aws\DoctrineCacheAdapter
        lazy:  true
        arguments:
            - "@doctrine_cache.providers.apcu"

    aws_credentials: aws_token_credentials
    aws_token_credentials:
        class: Aws\Credentials\Credentials
        lazy:  true
        arguments:
            - "%aws_credentials_key%"
            - "%aws_credentials_secret%"
    aws_instance_profile_credentials:
        class: Aws\Credentials\InstanceProfileProvider
        lazy:  true

The SQS Client is only using the default credentials, not the cache provider.

Supporting AWS SDK 2.x?

Because of reasons I am stuck with version 2.x of the AWS SDK.

At a first glance, there is so little code and configuration in this bundle here that I don't see why it wouldn't work with that (outdated) version.

Would you be open for a PR that would support the v2 version as well?

How To Authenticate a signed-in user

Hello,

May this is not the right position to ask such a question, but I have tried and searched How to authenticate a signed-in user but I did not find a clear sheet about this issue. And may I can get some help from you.

I installed this SDK successfully and I created my S3Client object succeffully. But I want to use S3Client obj to authenticate a signed-in users (from cognito users-pool), is that possible OR should I use kind of JS-SDK for this issue?

Do you have a concreted example how to?

Best regards,

AWS Cognito implementation

Package exist "pmill/aws-cognito" for providing some basic function to work with aws sdk and cognito but it does not seem to be maintained regularly.

If we can have implementation for it inside this package it will be easier to maintain projects which are using cognito and have up to date functions for it.

setFactoryService Deprecation errors

Hello,

using your bundle and also symfony/phpunit-bridge I am having tons of the following warnings :

Symfony\Component\DependencyInjection\Definition::setFactoryService(aws_sdk) is deprecated since > version 2.6 and will be removed in 3.0. Use Definition::setFactory() instead: 58x

Do you plan updating the bundle to get rid of these warnings ?

Regards.

[RFC] EnvVarProcessor using AWS Secrets Manager

Would anyone use a EnvVarProcessor that uses the AWS Secrets Manager?

What I'm thinking is to implement EnvVarProcessorInterface and create a awsSecret key that takes a SecretId, and optionally a versionID and / or versionStage and resolves this in runtime. Then in config, you can use a string similar to this to use amazon secrets in the config.

parameters:
    db_dsn: "mysql://db_user:%env(awsSecret:db_password)%@127.0.0.1:3306/db_name"

Thoughts? Does anyone want this? Would such a feature be merged?

[DOCUMENTATION] Update Documentation to Symfony 4 standards

Given the updated directory structure, the packages-level configurations, and the bundle registration not being in AppKernel any longer, I propose we update the 2.0.0 Documentation to reflect these kinds of changes. We can have a <= 3.4 version of the documentation available as well (or inline, depending on preference).

If I get a few thumbs up, I can work on that.

Support for upcomming Symfony 5

Please add support for upcomming Symfony 5.x

composer require aws/aws-sdk-php-symfony

results currently in:

./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Restricting packages listed in "symfony/symfony" to "5.0.*"
Your requirements could not be resolved to an installable set of packages.

Problem 1
- Installation request for aws/aws-sdk-php-symfony dev-master -> satisfiable by aws/aws-sdk-php-symfony[dev-master].
- aws/aws-sdk-php-symfony dev-master requires symfony/config ~2.3|~3.0|~4.0 -> no matching package found.

Potential causes:

Read https://getcomposer.org/doc/articles/troubleshooting.md for further common problems.

SQS Bulks issue

Describe the bug

I've tried pushing bulk payloads using sendMessageBatch and it pushed after that throws an exception

InvalidArgumentException {#17
  #message: """
    Found 1 error while validating the input provided for the SendMessageBatch operation:
    [Entries][0] must be an associative array. Found array(6)
    """
  #code: 0
  #file: "[/var/www/html/vendor/aws/aws-sdk-php/src/Api/Validator.php](https://my-dev-local.insead.edu/_profiler/open?file=vendor/aws/aws-sdk-php/src/Api/Validator.php&line=65#line65)"
  #line: 65 

I've seen my message into the queue via my console web so I don't know why its throw this exception and its works fine with same payload when I've used sendMessage

its strange behavior of it

Expected Behavior

pushing without expcetions

Current Behavior

sendMessageBatch throws an exception after push messages

Reproduction Steps

public function sendMessages(array $payload)
{
    $result = $this->client->sendMessageBatch($payload);
    $failed = $result->get('Failed');
    if (!empty($failed)) {
        foreach ($failed as $failure) {
            echo "Failed sending message: {$failure['Id']}, Code: {$failure['Code']}, Message: {$failure['Message']}\n";
        }
    }
    if (!empty($result->get('Successful'))) {
        foreach ($result->get('Successful') as $value) {
            echo "Successful sending message: {$value['Id']}\n<br/>";
        }
    }
}

Possible Solution

No response

Additional Information/Context

No response

SDK version used

2.6.1

Environment details (OS name and version, etc.)

ubuntu 20

Symfony 6.0 support

Is this related to a problem?

A new version of symfony released (6.0) yesterday.

Feature description

Add support for symfony 6.

Add support Symfony ^6.0

Describe the bug

Your requirements ~6.0 is not semantic. Add support for newer symfony minor versions please

Expected Behavior

Support symfony ^6.0

Current Behavior

~6.0, doesn't support newer minor versions

Reproduction Steps

Require symfony ^6.0 packages

Possible Solution

No response

Additional Information/Context

No response

SDK version used

2.5

Environment details (OS name and version, etc.)

all

Missing required client configuration options

I get this error after attempting to install (Symfony version 2.7.7):

  [InvalidArgumentException]                                                          
  Missing required client configuration options:                                      
  version: (string)                                                                   
    A "version" configuration value is required. Specifying a version constraint      
    ensures that your code will not be affected by a breaking change made to the      
    service. For example, when using Amazon S3, you can lock your API version to      
    "2006-03-01".                                                                     

    Your build of the SDK has the following version(s) of "s3": * "2006-03-01"        

    You may provide "latest" to the "version" configuration value to utilize the      
    most recent available API version that your client's API provider can find.       
    Note: Using 'latest' in a production application is not recommended.              

    A list of available API versions can be found on each client's API documentation  
    page: http://docs.aws.amazon.com/aws-sdk-php/v3/api/index.html. If you are        
    unable to load a specific API version, then you may need to update your copy of   
    the SDK.   
$ php -v
PHP 5.5.9-1ubuntu4.13 (cli) (built: Sep 29 2015 15:24:49) 
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies
    with Zend OPcache v7.0.3, Copyright (c) 1999-2014, by Zend Technologies

Example project

Hi, maybe you can create sample project, for understanding how to use symfony sdk

Setting region in configuration doesn't work

I tried the following

aws:
    version: latest
    region: eu-west-2
    credentials:
        key: "%aws_s3_credentials_key%"
        secret: "%aws_s3_credentials_secret%"
    s3:
        region: eu-west-2
    glacier:
        region: eu-west-1

But the region for my glacier service still is eu-west-2 :(

Deprecation notices in Symfony 3.3

I'm using the DynamoDB Session Handler in the PHP SDK in Symfony. To do this, I include this bundle and setup my own Session Handler in Symfony.

However, in doing so, I get the following deprecation notice on any and all requests:

Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should rename (or alias) the "aws.dynamodb" service to "Aws\DynamoDb\DynamoDbClient" instead.

I guess this is due to the way the compiler pass works? Anything I can do to silence these deprecations?

Thanks.

Handle merging of multiple configuration files

If I have two files in a typical flex application, config/packages/aws.yaml and config/packages/dev/aws.yaml, I'd expect anything in dev/aws.yaml to be merged into aws.yaml. Instead it completely replaces it:

aws.yaml

aws:
    region: eu-west-1
    credentials: ~
    version: latest
    retries: 5

dev/aws.yaml

aws:
    retries: 10

Expected

./bin/console debug:config aws --env=dev

aws:
    region: eu-west-1
    credentials: ~
    version: latest
    retries: 10

Actual

./bin/console debug:config aws --env=dev

aws:
    retries: 10

Because aws node is a variable node (see here), the configs aren't merged as normally expected with bundles, but completely replaced.

Either we should come up with a way to merge the configurations, or perhaps just document the behaviour somewhere?

composer show | grep aws
aws/aws-sdk-php                       3.69.9 
aws/aws-sdk-php-symfony              v2.0.0

Thank you.

Warnings creating ConfigBuilder

Please fill out the sections below to help us address your issue.

Version of AWS Service Provider for Symfony?

2.2.2

Version of Symfony (bin/console --version in project dir)?

5.3.2

Version of PHP (php -v)?

8.0.7

What issue did you see?

2.2.2

10:34:40 WARNING   [app] Failed to generate ConfigBuilder for extension Aws\Symfony\DependencyInjection\AwsExtension. ["exception" => LogicException { …},"extensionClass" => "Aws\Symfony\DependencyInjection\AwsExtension"]

Steps to reproduce

composer req aws/aws-sdk-php-symfony
bin/console cache:clear -v

As initial service config is in YAML format `symfony/yaml` should be required package

Describe the bug

if the project does not require the symfony/yaml app with this bundle will fail to boot

Expected Behavior

one of these

  • state that the yaml package is required composer
  • use php configuration in the bundle (preferred way)

Current Behavior

exception thrown on app/kernel boot

Reproduction Steps

create symfony starter project
configure it to use php configuration
remove symfony/yaml
install this bundle

Possible Solution

dev can add the symfony/yaml (even if the app itself has no need for it)

Additional Information/Context

No response

SDK version used

bundle: 2.5.0
sdk: not explicitly specified (resolved by composer)

Environment details (OS name and version, etc.)

N/A

Not working with Symfony 3.2.8

I cant seem to install this on symfony version 3.2.8

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Installation request for aws/aws-sdk-php-symfony dev-master -> satisfiable by aws/aws-sdk-php-symfony[dev-master].
    - aws/aws-sdk-php-symfony dev-master requires aws/aws-sdk-php ^3.2.6 -> satisfiable by aws/aws-sdk-php[3.10.0, 3.10.1, 3.11.0, 3.11.1, 3.11.2, 3.11.3, 3.11.4, 3.11.5, 3.11.6, 3.11.7, 3.12.0, 3.12.1, 3.12.2, 3.13.0, 3.13.1, 3.14.0, 3.14.1, 3.14.2, 3.15.0, 3.15.1, 3.15.2, 3.15.3, 3.15.4, 3.15.5, 3.15.6, 3.15.7, 3.15.8, 3.15.9, 3.16.0, 3.17.0, 3.17.1, 3.17.2, 3.17.3, 3.17.4, 3.17.5, 3.17.6, 3.18.0, 3.18.1, 3.18.10, 3.18.11, 3.18.12, 3.18.13, 3.18.14, 3.18.15, 3.18.16, 3.18.17, 3.18.18, 3.18.19, 3.18.2, 3.18.20, 3.18.21, 3.18.22, 3.18.23, 3.18.24, 3.18.25, 3.18.26, 3.18.27, 3.18.28, 3.18.29, 3.18.3, 3.18.30, 3.18.31, 3.18.32, 3.18.33, 3.18.34, 3.18.35, 3.18.36, 3.18.37, 3.18.38, 3.18.39, 3.18.4, 3.18.5, 3.18.6, 3.18.7, 3.18.8, 3.18.9, 3.19.0, 3.19.1, 3.19.10, 3.19.11, 3.19.12, 3.19.13, 3.19.14, 3.19.15, 3.19.16, 3.19.17, 3.19.18, 3.19.19, 3.19.2, 3.19.20, 3.19.21, 3.19.22, 3.19.23, 3.19.24, 3.19.25, 3.19.26, 3.19.27, 3.19.28, 3.19.29, 3.19.3, 3.19.30, 3.19.31, 3.19.32, 3.19.33, 3.19.4, 3.19.5, 3.19.6, 3.19.7, 3.19.8, 3.19.9, 3.2.6, 3.20.0, 3.20.1, 3.20.10, 3.20.11, 3.20.12, 3.20.13, 3.20.14, 3.20.15, 3.20.16, 3.20.2, 3.20.3, 3.20.4, 3.20.5, 3.20.6, 3.20.7, 3.20.8, 3.20.9, 3.21.0, 3.21.1, 3.21.2, 3.21.3, 3.21.4, 3.21.5, 3.21.6, 3.22.0, 3.22.1, 3.22.10, 3.22.11, 3.22.2, 3.22.3, 3.22.4, 3.22.5, 3.22.6, 3.22.7, 3.22.8, 3.22.9, 3.23.0, 3.23.1, 3.23.2, 3.23.3, 3.24.0, 3.24.1, 3.24.2, 3.24.3, 3.24.4, 3.24.5, 3.24.6, 3.24.7, 3.24.8, 3.24.9, 3.25.0, 3.25.1, 3.25.2, 3.25.3, 3.25.4, 3.25.5, 3.25.6, 3.25.7, 3.25.8, 3.26.0, 3.26.1, 3.26.2, 3.26.3, 3.26.4, 3.26.5, 3.27.0, 3.27.1, 3.27.2, 3.27.3, 3.27.4, 3.27.5, 3.28.0, 3.3.0, 3.3.1, 3.3.2, 3.3.3, 3.3.4, 3.3.5, 3.3.6, 3.3.7, 3.3.8, 3.4.0, 3.4.1, 3.5.0, 3.6.0, 3.7.0, 3.8.0, 3.8.1, 3.8.2, 3.9.0, 3.9.1, 3.9.2, 3.9.3, 3.9.4] but these conflict with your requirements or minimum-stability.

configure guzzle logger

Is this related to a problem?

If you use this bundle, nothing will be logged.

Feature description

I'd like the to configure guzzles logger by default.

Describe alternatives you've considered

You can configure it but it isn't too obvious:

aws:
    version: latest
    region: '%env(AWS_REGION)%'
    http:
        handler: '@aws.http_handler'

services:
    aws.http_handler:
        class: GuzzleHttp\HandlerStack
        factory: [GuzzleHttp\HandlerStack, create]
        calls:
            - [push, ['@aws.http_logger']]
    
    aws.http_logger:
        class: Closure
        factory: [GuzzleHttp\Middleware, log]
        arguments:
            - '@logger'
            - '@aws.log_formatter'
        tags:
            - {name: monolog.logger, channel: aws}

    aws.log_formatter:
        class: GuzzleHttp\MessageFormatter
        arguments:
            - '{method} {uri} HTTP/{version} {code}'

This configuration doesn't validate though as the handler option isn't defined here.

You can also the 8p/EightPointsGuzzleBundle and configure the http_handler option (don't confuse it with the http.handler option from above) to pass a preconfigured Guzzle instance.

bundle fails with symfony 2.4

I think the quick fix would be to declare that it depends on Symfony 2.5 or later.

The error is:
PHP Fatal error: Call to undefined method Symfony\Component\DependencyInjection\Definition::setFactory() in /home/travis/build/kaliop-uk/kueueingbundle-kinesis/vendor/aws/aws-sdk-php-symfony/src/DependencyInjection/AwsExtension.php on line 53

You can see more in the Travis logs of this build: https://travis-ci.org/kaliop-uk/kueueingbundle-kinesis/jobs/78941465

Symfony 7 support

Describe the feature

Hi there,
Symfony 7 was released recently, and it would be super awesome if this package's composer.json file could also be updated with v7 support.
Thank you for a really great package by the way -- it's very very nice!

Use Case

Symfony 7 is the latest major update to the framework, and without subsequent updates to packages such as this one, it means users of those packages cannot update their software accordingly.

Proposed Solution

Update references to symfony pacakges to include v7 in the composer.json file.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

SDK version used

latest

Environment details (OS name and version, etc.)

OSX, latest

Non-negligible memory usage when not even using the client

Please fill out the sections below to help us address your issue.

Version of AWS SDK for PHP?

3.98.0

Version of AWS Service Provider for Symfony?

2.0.1

Version of Symfony (bin/console --version in project dir)?

4.3.3

Version of PHP (php -v)?

7.1.28

What issue did you see?

When using any Symfony CLI command, every command is instantiated. If a command relies on a S3Client, the S3Client will be instantiated too, and this seems to use a lot of memory, because it is loading a huge json file.

Screenshot_2019-11-07 Untitled profile - Blackfire

Steps to reproduce

  1. Create a Symfony Command that requires an S3Client instance
  2. Run any command (can be another command)

Setting the service as lazy results in a 15% performance gain (thanks Blackfire).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.