Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Symfony 4. Problem with cache and source file editing. #24

Open
klimick opened this issue Jun 3, 2018 · 2 comments
Open

Symfony 4. Problem with cache and source file editing. #24

klimick opened this issue Jun 3, 2018 · 2 comments

Comments

@klimick
Copy link

klimick commented Jun 3, 2018

Hello! I have problems with editing source files. Aspects stop working after any change in the source file that works under the aspect. After running the cache:clear command, all aspects continue to work until a new change is made to the source file.
I'm using symfony 4.0.5 with autowiring.

The aspects that I use:

/**
     * @Before("execution(public **\Application\**\*Service->*(*)) && !execution(public **\Application\**\*Service->__construct(*))")
     */
    public function beginTransaction()
    {
        $this->entityManager->getConnection()->beginTransaction();
        $this->entityManager->getConnection()->setAutoCommit(false);
    }

    /**
     * @After("execution(public **\Application\**\*Service->*(*)) && !execution(public **\Application\**\*Service->__construct(*))")
     */
    public function commitTransaction()
    {
        $this->entityManager->flush();
        $this->entityManager->getConnection()->commit();
    }

    /**
     * @AfterThrowing("execution(public **\Application\**\*Service->*(*)) && !execution(public **\Application\**\*Service->__construct(*))")
     */
    public function rollbackTransaction()
    {
        if ($this->entityManager->getConnection()->isTransactionActive()) {
            $this->entityManager->rollback();
        }
    }
@lisachenko
Copy link
Member

Hi, unfortunately a lot of things have changed in SF4, so need to update this bundle accordingly. Current bundle version couldn't handle new symfony. Sorry for that.

@lisachenko
Copy link
Member

Related to #22

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants