You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Martin Thelian (JIRA)" <ji...@apache.org> on 2008/11/07 10:58:44 UTC
[jira] Created: (FELIX-809) MonitorAdmin - mon.statusvariable.value
should be a String
MonitorAdmin - mon.statusvariable.value should be a String
----------------------------------------------------------
Key: FELIX-809
URL: https://issues.apache.org/jira/browse/FELIX-809
Project: Felix
Issue Type: Bug
Components: Sandbox
Reporter: Martin Thelian
As defined in the OSGi spec 4.1 the MonitorAdminImpl should send the StatusVariable value as String:
"The events posted by MonitorAdmin contain the following properties:
[...]
• mon.statusvariable.value: The value of the StatusVariable, represented as a String"
Currently the value is converted into Integer/Float/Boolean or String:
-----
| switch (statusVariable.getType()) { // TODO float->double, int->long
| case StatusVariable.TYPE_BOOLEAN:
| value = new Boolean(statusVariable.getBoolean());
| break;
| case StatusVariable.TYPE_FLOAT:
| value = new Float(statusVariable.getFloat());
| break;
| case StatusVariable.TYPE_INTEGER:
| value = new Integer(statusVariable.getInteger());
| break;
| case StatusVariable.TYPE_STRING:
| value = statusVariable.getString();
| break;
| }
| properties.put(MON_STATUSVARIABLE_VALUE, value);
-----
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (FELIX-809) MonitorAdmin - mon.statusvariable.value
should be a String
Posted by "Martin Thelian (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-809?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Thelian updated FELIX-809:
---------------------------------
Attachment: FELIX-809.patch
Here is a patch to fix this issue.
> MonitorAdmin - mon.statusvariable.value should be a String
> ----------------------------------------------------------
>
> Key: FELIX-809
> URL: https://issues.apache.org/jira/browse/FELIX-809
> Project: Felix
> Issue Type: Bug
> Components: Sandbox
> Reporter: Martin Thelian
> Attachments: FELIX-809.patch
>
>
> As defined in the OSGi spec 4.1 the MonitorAdminImpl should send the StatusVariable value as String:
> "The events posted by MonitorAdmin contain the following properties:
> [...]
> • mon.statusvariable.value: The value of the StatusVariable, represented as a String"
> Currently the value is converted into Integer/Float/Boolean or String:
> -----
> | switch (statusVariable.getType()) { // TODO float->double, int->long
> | case StatusVariable.TYPE_BOOLEAN:
> | value = new Boolean(statusVariable.getBoolean());
> | break;
> | case StatusVariable.TYPE_FLOAT:
> | value = new Float(statusVariable.getFloat());
> | break;
> | case StatusVariable.TYPE_INTEGER:
> | value = new Integer(statusVariable.getInteger());
> | break;
> | case StatusVariable.TYPE_STRING:
> | value = statusVariable.getString();
> | break;
> | }
> | properties.put(MON_STATUSVARIABLE_VALUE, value);
> -----
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (FELIX-809) MonitorAdmin -
mon.statusvariable.value should be a String
Posted by "Didier DONSEZ (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-809?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Didier DONSEZ resolved FELIX-809.
---------------------------------
Resolution: Fixed
Assignee: Didier DONSEZ
the patch was applied and tested with the demo script felix/sandbox/donsez/script/monitor.txt
and commited at revision: 713734
> MonitorAdmin - mon.statusvariable.value should be a String
> ----------------------------------------------------------
>
> Key: FELIX-809
> URL: https://issues.apache.org/jira/browse/FELIX-809
> Project: Felix
> Issue Type: Bug
> Components: Sandbox
> Reporter: Martin Thelian
> Assignee: Didier DONSEZ
> Attachments: FELIX-809.patch
>
>
> As defined in the OSGi spec 4.1 the MonitorAdminImpl should send the StatusVariable value as String:
> "The events posted by MonitorAdmin contain the following properties:
> [...]
> • mon.statusvariable.value: The value of the StatusVariable, represented as a String"
> Currently the value is converted into Integer/Float/Boolean or String:
> -----
> | switch (statusVariable.getType()) { // TODO float->double, int->long
> | case StatusVariable.TYPE_BOOLEAN:
> | value = new Boolean(statusVariable.getBoolean());
> | break;
> | case StatusVariable.TYPE_FLOAT:
> | value = new Float(statusVariable.getFloat());
> | break;
> | case StatusVariable.TYPE_INTEGER:
> | value = new Integer(statusVariable.getInteger());
> | break;
> | case StatusVariable.TYPE_STRING:
> | value = statusVariable.getString();
> | break;
> | }
> | properties.put(MON_STATUSVARIABLE_VALUE, value);
> -----
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (FELIX-809) MonitorAdmin - mon.statusvariable.value
should be a String
Posted by "Martin Thelian (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-809?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Thelian closed FELIX-809.
--------------------------------
I'm now using the new snapshot version for a few days in my environment and it works fine. Thanks.
> MonitorAdmin - mon.statusvariable.value should be a String
> ----------------------------------------------------------
>
> Key: FELIX-809
> URL: https://issues.apache.org/jira/browse/FELIX-809
> Project: Felix
> Issue Type: Bug
> Components: Sandbox
> Reporter: Martin Thelian
> Assignee: Didier DONSEZ
> Attachments: FELIX-809.patch
>
>
> As defined in the OSGi spec 4.1 the MonitorAdminImpl should send the StatusVariable value as String:
> "The events posted by MonitorAdmin contain the following properties:
> [...]
> • mon.statusvariable.value: The value of the StatusVariable, represented as a String"
> Currently the value is converted into Integer/Float/Boolean or String:
> -----
> | switch (statusVariable.getType()) { // TODO float->double, int->long
> | case StatusVariable.TYPE_BOOLEAN:
> | value = new Boolean(statusVariable.getBoolean());
> | break;
> | case StatusVariable.TYPE_FLOAT:
> | value = new Float(statusVariable.getFloat());
> | break;
> | case StatusVariable.TYPE_INTEGER:
> | value = new Integer(statusVariable.getInteger());
> | break;
> | case StatusVariable.TYPE_STRING:
> | value = statusVariable.getString();
> | break;
> | }
> | properties.put(MON_STATUSVARIABLE_VALUE, value);
> -----
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.