0

I have an issue in a new devkit Project where the following @ValidateConnection method is failing to be called (but my @processor methods are called fine when requested in the flows)

 @ValidateConnection
    public boolean isConnected() {
        return isConnected;
    }

I thought that the above should be called to check whether to call the @Connect method.

I think it is because I am using a non default category (Components) for the connector

@Category(name = "org.mule.tooling.category.core", description = "Components")

And the resulting Behavoir is different to what I am used to with DevKit in Cloud connector mode.

I guess I will need to do checks in each @processor for now to see if the initialization logic is done, as there doesn't seem to be an easy way to run a one time config.

EDIT_________________ I actually tried porting it back to a cloud connector @cat and the same behaviour, maybe its an issue with devkit -DarchetypeVersion=3.4.0, I used 3.2.x somthing before and things worked a bit better

4

1 に答える 1

1

@ValidateConnectionアノテーション付きメソッドは、生成されたクラス@Connectorのメソッドの最後で呼び出されます。誰があなたを呼んでいるかの参照を探すと、これを確認できるはずです.makeObject()*ConnectionFactoryisConnected()

いいえ、チェックを実行する必要はありません。自動的に実行されるはずです。

何か他に欠けているものがあるに違いありません...@ConnectionIdentifier注釈付きのメソッドはありますか?

PS。@Category注釈は、Studio での純粋な表示目的のためのものです。

于 2013-07-11T15:56:25.450 に答える