-
1. Re: Paging Configuration
timfox Jan 6, 2010 2:51 PM (in response to jcesarfs)No, you need to use AddressSettings -
2. Re: Paging Configuration
jcesarfs Jan 7, 2010 3:47 PM (in response to timfox)Hy Tim, thanks for you response.
Now, I'm trying to set the AddressSettings, but the warning message about the available memory are printed the same way.
The code below it's correct?
try {
configuration.start();
server = HornetQ.newHornetQServer(configuration);
server.start();addressSet = server.getAddressSettingsRepository();
queueSetting = new AddressSettings();
queueSetting.setMaxSizeBytes(10485760);
queueSetting.setPageSizeBytes(1048576);
addressSet.setDefault(queueSetting);connectionFactory = new HornetQConnectionFactory(new TransportConfiguration(InVMConnectorFactory.class.getName()));
clientSession = connectionFactory.getCoreFactory().createSession();try {
clientSession.createQueue("queueName", "queueName", true);
} catch (HornetQException e) {
if (e.getCode() != HornetQException.QUEUE_EXISTS)
e.printStackTrace();
}} catch (Exception e) {
e.printStackTrace();
}Thanks,
Julio
-
3. Re: Paging Configuration
clebert.suconic Jan 7, 2010 4:19 PM (in response to jcesarfs)Did you read this other thread about paging? (next one on the forums)
-
4. Re: Paging Configuration
jcesarfs Jan 7, 2010 4:30 PM (in response to clebert.suconic)Hy Clebert,
Yes I read it.
Are you asking becouse the ACK?
Yes, I'm acknowledging the messages.My problem is whith this warning:
Jan 6, 2010 9:43:54 PM org.hornetq.core.logging.Logger warn
WARNING: Less than 25%
free memory: 2.80 kiB
max memory: 63.56 MiB
total memory: 63.56 MiB
available memory: 0.00%You are in danger of running out of RAM. Have you set paging parameters on your addresses? (See user manual "Paging" chapter)
-
5. Re: Paging Configuration
clebert.suconic Jan 7, 2010 4:40 PM (in response to jcesarfs)Hmmm.. I'm not sure if the setDefault would work on the AddressSettingsRepository for paging. (If that's the case you could maybe open a JIRA?)
Can you try this instead?
AddressSettings defaultSetting = new AddressSettings();
defaultSetting.setPageSizeBytes(pageSize);
defaultSetting.setMaxSizeBytes(maxAddressSize);server.getAddressSettingsRepository().addMatch("#", defaultSetting);