@@ -9,8 +9,16 @@ Property Port As %Integer [ InitialExpression = -1 ];
9
9
10
10
Property VirtualHost As %String [ InitialExpression = " /" ];
11
11
12
+ /// Outbound adapter only (ignored for inbound adapter)
13
+ /// If Exchange is not set, then Queue name.
14
+ /// If Exchange is set, then Routing Key.
12
15
Property Queue As %String ;
13
16
17
+ /// Exchange name.
18
+ /// Optional, empty by default.
19
+ /// If set, Queue becomes Routing Key.
20
+ Property Exchange As %String ;
21
+
14
22
/// Config Name of the Java Gateway service controlling the Java Gateway server this item will use.
15
23
/// Alternatively use JGHost and JGPort Settings, to specify Java gateway outside of Ensemble scope.
16
24
Property JGService As %String ;
@@ -40,7 +48,7 @@ Property Encoding As %String;
40
48
Property ClassPath As %String (MAXLEN = 32000 );
41
49
42
50
/// These are the production settings for this object
43
- Parameter SETTINGS = " Host:Basic,Port:Basic,VirtualHost:Basic,Queue:Basic,Credentials:Basic:credentialsSelector,JGHost:Java Gateway,JGPort:Java Gateway,JGService:Java Gateway:selector?context={Ens.ContextSearch/ProductionItems?targets=0&productionName=@productionId},ClassPath:Basic,Encoding:Basic" ;
51
+ Parameter SETTINGS = " Host:Basic,Port:Basic,VirtualHost:Basic,Queue:Basic,Exchange:Basic, Credentials:Basic:credentialsSelector,JGHost:Java Gateway,JGPort:Java Gateway,JGService:Java Gateway:selector?context={Ens.ContextSearch/ProductionItems?targets=0&productionName=@productionId},ClassPath:Basic,Encoding:Basic" ;
44
52
45
53
/// Connect to running JGW
46
54
Method Connect () As %Status
@@ -82,7 +90,7 @@ Method ConnectToRabbitMQ() As %Status
82
90
}
83
91
84
92
Try {
85
- Set ..API = ##class (isc.rabbitmq.API ).%New (..JGW , ..Host , ..Port , user , pass , ..VirtualHost , ..Queue , $$$YES)
93
+ Set ..API = ##class (isc.rabbitmq.API ).%New (..JGW , ..Host , ..Port , user , pass , ..VirtualHost , ..Queue , $$$YES, .. Exchange )
86
94
} Catch ex {
87
95
Set sc = ..ExceptionToStatus (ex )
88
96
}
0 commit comments