You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jmeter.apache.org by "salmansharifov (via GitHub)" <gi...@apache.org> on 2023/05/20 19:48:48 UTC

[GitHub] [jmeter] salmansharifov opened a new pull request, #5940: object passed for parameter instead of string

salmansharifov opened a new pull request, #5940:
URL: https://github.com/apache/jmeter/pull/5940

   ## Description
   <!--- Provide a general summary of your changes in the Title above -->
   <!--- Describe your changes in detail here -->
   
   ## Motivation and Context
   <!--- Why is this change required? What problem does it solve? -->
   <!--- If it fixes an open issue, please link to the issue here. -->
   https://github.com/apache/jmeter/issues/5922
   
   ## How Has This Been Tested?
   <!--- Please describe in detail how you tested your changes. -->
   <!--- Include details of your testing environment, tests ran to see how -->
   <!--- your change affects other areas of the code, etc. -->
   
   ## Screenshots (if appropriate):
   
   ## Types of changes
   <!--- What types of changes does your code introduce? Delete as appropriate -->
   - Bug fix (non-breaking change which fixes an issue)
   - New feature (non-breaking change which adds functionality)
   - Breaking change (fix or feature that would cause existing functionality to not work as expected)
   
   ## Checklist:
   <!--- Go over all the following points, and put an `x` in all the boxes that apply. -->
   <!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->
   - [x] My code follows the [code style][style-guide] of this project.
   - [ ] I have updated the documentation accordingly.
   
   [style-guide]: https://wiki.apache.org/jmeter/CodeStyleGuidelines
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [jmeter] salmansharifov commented on pull request #5940: object passed for parameter instead of string

Posted by "salmansharifov (via GitHub)" <gi...@apache.org>.
salmansharifov commented on PR #5940:
URL: https://github.com/apache/jmeter/pull/5940#issuecomment-1556229707

   adding `:src:core` dependency to `:src:jorphan `for JMeterProperty cause cyclic dependency error.  Is there way to tackle this?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [jmeter] vlsi commented on pull request #5940: object passed for parameter instead of string

Posted by "vlsi (via GitHub)" <gi...@apache.org>.
vlsi commented on PR #5940:
URL: https://github.com/apache/jmeter/pull/5940#issuecomment-1556166974

   not really. Something like
   
   ```java
   ... getInt(...){
   if (value instanceof JMeterProperty) {
       return value.getIntegerValue();
   }
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [jmeter] vlsi commented on pull request #5940: object passed for parameter instead of string

Posted by "vlsi (via GitHub)" <gi...@apache.org>.
vlsi commented on PR #5940:
URL: https://github.com/apache/jmeter/pull/5940#issuecomment-1556235575

   Oh, I did not think about it.
   
   One of the options could be: make intproperty implement Number.
   
   An alternative option could be adding a custom interface to jorphan that could be implemented in jmeterproperty


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [jmeter] salmansharifov commented on pull request #5940: object passed for parameter instead of string

Posted by "salmansharifov (via GitHub)" <gi...@apache.org>.
salmansharifov commented on PR #5940:
URL: https://github.com/apache/jmeter/pull/5940#issuecomment-1574332900

   Sorry, but I couldn't handle the solution. Do you know any resource for interface solution?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [jmeter] vlsi commented on pull request #5940: object passed for parameter instead of string

Posted by "vlsi (via GitHub)" <gi...@apache.org>.
vlsi commented on PR #5940:
URL: https://github.com/apache/jmeter/pull/5940#issuecomment-1556077522

   I guess you'll need to add `JMeterProperty` handling to `org.apache.jorphan.util.Converter#getInt(java.lang.Object)`, `getLong`, and similar relevant methods.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [jmeter] salmansharifov commented on pull request #5940: object passed for parameter instead of string

Posted by "salmansharifov (via GitHub)" <gi...@apache.org>.
salmansharifov commented on PR #5940:
URL: https://github.com/apache/jmeter/pull/5940#issuecomment-1556157560

   Like that?
   ```
    public static int getInt(JMeterProperty o) {
           Object objectValue = o.getObjectValue();
           return getInt(objectValue, 0);
       }
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [jmeter] vlsi commented on pull request #5940: object passed for parameter instead of string

Posted by "vlsi (via GitHub)" <gi...@apache.org>.
vlsi commented on PR #5940:
URL: https://github.com/apache/jmeter/pull/5940#issuecomment-1577159660

   One of the ways would be add a converter in `:src:core` so it would try convert the properties first, and if the element is not a property, then delegate to the converter in `jorphan`.
   
   WDYT?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jmeter.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org