[ARTEMIS-1197] Add missing role to default OSGi configuration
This commit is contained in:
parent
2d8c8d446c
commit
71fc3a8bb5
|
@ -84,6 +84,7 @@ under the License.
|
||||||
<permission type="deleteAddress" roles="manager"/>
|
<permission type="deleteAddress" roles="manager"/>
|
||||||
<permission type="consume" roles="manager"/>
|
<permission type="consume" roles="manager"/>
|
||||||
<permission type="send" roles="manager"/>
|
<permission type="send" roles="manager"/>
|
||||||
|
<permission type="browse" roles="manager"/>
|
||||||
<!-- we need this otherwise ./artemis data imp wouldn't work -->
|
<!-- we need this otherwise ./artemis data imp wouldn't work -->
|
||||||
<permission type="manage" roles="manager"/>
|
<permission type="manage" roles="manager"/>
|
||||||
</security-setting>
|
</security-setting>
|
||||||
|
|
|
@ -22,6 +22,7 @@ import javax.jms.Message;
|
||||||
import javax.jms.MessageConsumer;
|
import javax.jms.MessageConsumer;
|
||||||
import javax.jms.MessageProducer;
|
import javax.jms.MessageProducer;
|
||||||
import javax.jms.Queue;
|
import javax.jms.Queue;
|
||||||
|
import javax.jms.QueueBrowser;
|
||||||
import javax.security.auth.Subject;
|
import javax.security.auth.Subject;
|
||||||
import java.io.ByteArrayOutputStream;
|
import java.io.ByteArrayOutputStream;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
|
@ -29,6 +30,7 @@ import java.io.PrintStream;
|
||||||
import java.security.PrivilegedAction;
|
import java.security.PrivilegedAction;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
|
import java.util.Enumeration;
|
||||||
import java.util.concurrent.Callable;
|
import java.util.concurrent.Callable;
|
||||||
import java.util.concurrent.ExecutorService;
|
import java.util.concurrent.ExecutorService;
|
||||||
import java.util.concurrent.Executors;
|
import java.util.concurrent.Executors;
|
||||||
|
@ -151,6 +153,14 @@ public class ArtemisFeatureTest extends Assert {
|
||||||
MessageProducer producer = sess.createProducer(queue);
|
MessageProducer producer = sess.createProducer(queue);
|
||||||
producer.send(sess.createTextMessage("TEST"));
|
producer.send(sess.createTextMessage("TEST"));
|
||||||
|
|
||||||
|
// Test browsing
|
||||||
|
try (QueueBrowser browser = sess.createBrowser(queue)) {
|
||||||
|
Enumeration messages = browser.getEnumeration();
|
||||||
|
while (messages.hasMoreElements()) {
|
||||||
|
messages.nextElement();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
MessageConsumer consumer = sess.createConsumer(queue);
|
MessageConsumer consumer = sess.createConsumer(queue);
|
||||||
Message msg = consumer.receive(5000);
|
Message msg = consumer.receive(5000);
|
||||||
assertNotNull(msg);
|
assertNotNull(msg);
|
||||||
|
|
Loading…
Reference in New Issue