[SNMP4J] GET on Table with several indexes .
wafae alami
alami.ouafae at gmail.com
Thu Sep 17 13:14:05 CEST 2009
Thanks Frank for the response .
Actually , I have seen the jvmMemMgrPoolRelEntry implementation , in the
JvmManagementMib.java the jvmMemMgrPoolRelEntry is implemented with two
indexes , but in the JvmManagementMibInst.java there is no implementation of
the jvmMemMgrPoolRelEntry.
my problem exactely is how to implement the mapToRowMBean method to return
the ObjectName . and what's kind of keyProvider use .
tableSupport.add(OID tableEntry ,
new MBeanAttributeMOTableInfo(ObjectName name,
*MBeanAttributeKeyProvider keyProvider*,
TypedAttribute[] columns,
String[] keyAttributes,
*JMXIndexSupport indexSupport*) )
I implement the *indexSupport *as follows :
*JMXIndexSupport indexSupport *=
new AbstractSyntheticJMXIndexSupport() {
* public ObjectName mapToRowMBean(Object rowIdentifier) {
try {
Object[] rowsID=(Object[])rowIdentifier;
return new ObjectName("ProxyPlatform " +",name=" +
rowID[0]+",group="+rowID[1]);
}
catch (Exception ex) {
ex.printStackTrace();
return null;
}
}*
}
the ObjectName is well returned , but when I make a get request on the
"name" attribute of this table , I get sometimes more than one row ,
sometimes one row , two rows , and sometimes more , and it's a random
behavior .
I don't know if the other methods of JMXIndexSupport should also be
re-implemented . but I think it's an indexing problem .
Thanks in advance
Ouafae.
2009/9/16 Frank Fock <fock at agentpp.com>
> Hi Ouafae,
>
> Have you seen the jvmMemMgrPoolRelEntry implementation
> in the JvmManagementMib[Inst].java file?
> This is an example for a multiple sub-index implementation.
>
> Best regards,
> Frank
>
> wafae alami wrote:
>
>> hi every one ,
>>
>> please there is any one does has an idea how to imlement a table with
>> several indexes ? the kind of key provider ?
>>
>>
>> Thanks
>> Ouafae
>> _______________________________________________
>> SNMP4J mailing list
>> SNMP4J at agentpp.org
>> http://lists.agentpp.org/mailman/listinfo/snmp4j
>>
>
> --
> AGENT++
> http://www.agentpp.com
> http://www.snmp4j.com
> http://www.mibexplorer.com
> http://www.mibdesigner.com
>
>
--
Ouafae ALAMI (Promotion INPT 2007)
Ingénieur de Convergence a Alcatel-Lucent
Projet Ims Application Server.
More information about the SNMP4J
mailing list