Git Product home page Git Product logo

postman2jmx's Issues

Getting java error while generating jar file

Exception in thread "main" java.lang.ExceptionInInitializerError
at com.thoughtworks.xstream.XStream.setupConverters(XStream.java:989)
at com.thoughtworks.xstream.XStream.(XStream.java:592)
at com.thoughtworks.xstream.XStream.(XStream.java:514)
at com.thoughtworks.xstream.XStream.(XStream.java:483)
at com.thoughtworks.xstream.XStream.(XStream.java:429)
at com.thoughtworks.xstream.XStream.(XStream.java:382)
at org.apache.jmeter.save.SaveService$XStreamWrapper.(SaveService.java:82)
at org.apache.jmeter.save.SaveService$XStreamWrapper.(SaveService.java:80)
at org.apache.jmeter.save.SaveService.(SaveService.java:113)
at com.loadium.postman2jmx.builder.AbstractJmxFileBuilder.buildJmxFile(AbstractJmxFileBuilder.java:104)
at com.loadium.postman2jmx.builder.JmxFileBuilder.build(JmxFileBuilder.java:10)
at com.loadium.postman2jmx.app.Postman2Jmx.main(Postman2Jmx.java:35)
Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make field private final java.util.Comparator java.util.TreeMap.comparator accessible: module java.base does not "opens java.util" to unnamed module @11e21d0e
at java.base/java.lang.reflect.AccessibleObject.throwInaccessibleObjectException(AccessibleObject.java:387)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:363)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:311)
at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:181)
at java.base/java.lang.reflect.Field.setAccessible(Field.java:175)
at com.thoughtworks.xstream.core.util.Fields.locate(Fields.java:40)
at com.thoughtworks.xstream.converters.collections.TreeMapConverter.(TreeMapConverter.java:50)

readme document issue

now it's "java -jar name.json name.jmx"
should be "java -jar Postman2jmx.jar name.json name.jmx"

CookieManager.name.prefix some warning messages

[21-七月-26 21:05:47:676] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'jmeterengine.threadstop.wait', defaulting to: 5000
[21-七月-26 21:05:47:677] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'jmeterthread.rampup.granularity', defaulting to: 1000
[21-七月-26 21:05:47:694] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_bytes_to_store_per_request', defaulting to: 0
[21-七月-26 21:05:47:694] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_buffer_size', defaulting to: 66560
[21-七月-26 21:05:47:695] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.ignore_failed_embedded_resources', defaulting to: false
[21-七月-26 21:05:47:698] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.embedded_resources_use_md5', defaulting to: false
[21-七月-26 21:05:47:700] [WARN] [JMeterUtils:794] - Exception 'null' occurred when fetching String property:'httpsampler.user_defined_methods', defaulting to:
[21-七月-26 21:05:47:706] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_redirects', defaulting to: 20
[21-七月-26 21:05:47:706] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_frame_depth', defaulting to: 5
[21-七月-26 21:05:47:707] [WARN] [JMeterUtils:812] - Exception 'null' occurred when fetching String property:'HTTPResponse.parsers'
[21-七月-26 21:05:47:710] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.redirect.removeslashdotdot', defaulting to: true
[21-七月-26 21:05:47:711] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.separate.container', defaulting to: true
[21-七月-26 21:05:47:739] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'CookieManager.delete_null_cookies', defaulting to: true
[21-七月-26 21:05:47:740] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'CookieManager.allow_variable_cookies', defaulting to: true
[21-七月-26 21:05:47:741] [WARN] [JMeterUtils:794] - Exception 'null' occurred when fetching String property:'CookieManager.name.prefix', defaulting to: COOKIE_
[21-七月-26 21:05:47:744] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'CookieManager.save.cookies', defaulting to: false
[21-七月-26 21:05:47:745] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'CookieManager.check.cookies', defaulting to: true
[21-七月-26 21:05:47:746] [INFO] [CookieManager:87] - Settings: Delete null: true Check: true Allow variable: true Save: false Prefix: COOKIE_
[21-七月-26 21:05:47:955] [INFO] [SaveService:163] - Testplan (JMX) version: 2.2. Testlog (JTL) version: 2.2
[21-七月-26 21:05:47:961] [WARN] [JMeterUtils:794] - Exception 'null' occurred when fetching String property:'saveservice_properties', defaulting to: /bin/saveservice.properties
[21-七月-26 21:05:47:974] [WARN] [JMeterUtils:794] - Exception 'null' occurred when fetching String property:'saveservice_properties', defaulting to: /bin/saveservice.properties

Oracle APIs Postman Collection

Hi,

Getting exceptions with most of these

https://github.com/oracle/hospitality-api-docs/tree/main/postman-collections

[23-Jan-19 12:17:17:671] [INFO] [Postman2Jmx:33] - Trying to build jmx file: workflows.jmx
[23-Jan-19 12:17:17:704] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'jmeterengine.threadstop.wait', defaulting to: 5000
[23-Jan-19 12:17:17:704] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'jmeterthread.rampup.granularity', defaulting to: 1000
[23-Jan-19 12:17:17:719] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_bytes_to_store_per_request', defaulting to: 0
[23-Jan-19 12:17:17:719] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_buffer_size', defaulting to: 66560
[23-Jan-19 12:17:17:719] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.ignore_failed_embedded_resources', defaulting to: false
[23-Jan-19 12:17:17:719] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.embedded_resources_use_md5', defaulting to: false
[23-Jan-19 12:17:17:720] [WARN] [JMeterUtils:794] - Exception 'null' occurred when fetching String property:'httpsampler.user_defined_methods', defaulting to:
[23-Jan-19 12:17:17:723] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_redirects', defaulting to: 20
[23-Jan-19 12:17:17:723] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_frame_depth', defaulting to: 5
[23-Jan-19 12:17:17:723] [WARN] [JMeterUtils:812] - Exception 'null' occurred when fetching String property:'HTTPResponse.parsers'
[23-Jan-19 12:17:17:723] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.redirect.removeslashdotdot', defaulting to: true
[23-Jan-19 12:17:17:724] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.separate.container', defaulting to: true
[23-Jan-19 12:17:17:736] [ERROR] [Postman2Jmx:39] - Error occurred!
java.lang.IllegalArgumentException: Name cannot be null
        at org.apache.jmeter.testelement.property.AbstractProperty.<init>(AbstractProperty.java:40) ~[ApacheJMeter_core-4.0.jar:4.0 r1823414]
        at org.apache.jmeter.testelement.property.MultiProperty.<init>(MultiProperty.java:36) ~[ApacheJMeter_core-4.0.jar:4.0 r1823414]
        at org.apache.jmeter.testelement.property.TestElementProperty.<init>(TestElementProperty.java:31) ~[ApacheJMeter_core-4.0.jar:4.0 r1823414]
        at org.apache.jmeter.config.Arguments.addArgument(Arguments.java:119) ~[ApacheJMeter_core-4.0.jar:4.0 r1823414]
        at com.loadium.postman2jmx.model.jmx.JmxHTTPSamplerProxy.newInstance(JmxHTTPSamplerProxy.java:88) ~[Postman2Jmx.jar:?]
        at com.loadium.postman2jmx.builder.JmxRawBodyBuilder.buildJmxBody(JmxRawBodyBuilder.java:18) ~[Postman2Jmx.jar:?]
        at com.loadium.postman2jmx.builder.AbstractJmxFileBuilder.buildJmxFile(AbstractJmxFileBuilder.java:62) ~[Postman2Jmx.jar:?]
        at com.loadium.postman2jmx.builder.JmxFileBuilder.build(JmxFileBuilder.java:10) ~[Postman2Jmx.jar:?]
        at com.loadium.postman2jmx.app.Postman2Jmx.main(Postman2Jmx.java:35) [Postman2Jmx.jar:?]

and

[23-Jan-19 12:15:10:605] [INFO] [Postman2Jmx:33] - Trying to build jmx file: test.jmx
[23-Jan-19 12:15:10:659] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'jmeterengine.threadstop.wait', defaulting to: 5000
[23-Jan-19 12:15:10:660] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'jmeterthread.rampup.granularity', defaulting to: 1000
[23-Jan-19 12:15:10:675] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_bytes_to_store_per_request', defaulting to: 0
[23-Jan-19 12:15:10:676] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_buffer_size', defaulting to: 66560
[23-Jan-19 12:15:10:676] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.ignore_failed_embedded_resources', defaulting to: false
[23-Jan-19 12:15:10:676] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.embedded_resources_use_md5', defaulting to: false
[23-Jan-19 12:15:10:677] [WARN] [JMeterUtils:794] - Exception 'null' occurred when fetching String property:'httpsampler.user_defined_methods', defaulting to:
[23-Jan-19 12:15:10:680] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_redirects', defaulting to: 20
[23-Jan-19 12:15:10:681] [WARN] [JMeterUtils:703] - Exception 'null' occurred when fetching int property:'httpsampler.max_frame_depth', defaulting to: 5
[23-Jan-19 12:15:10:681] [WARN] [JMeterUtils:812] - Exception 'null' occurred when fetching String property:'HTTPResponse.parsers'
[23-Jan-19 12:15:10:681] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.redirect.removeslashdotdot', defaulting to: true
[23-Jan-19 12:15:10:681] [WARN] [JMeterUtils:730] - Exception 'null' occurred when fetching boolean property:'httpsampler.separate.container', defaulting to: true
[23-Jan-19 12:15:10:700] [ERROR] [Postman2Jmx:39] - Error occurred!
java.lang.IllegalArgumentException: Name cannot be null
        at org.apache.jmeter.testelement.property.AbstractProperty.<init>(AbstractProperty.java:40) ~[ApacheJMeter_core-4.0.jar:4.0 r1823414]
        at org.apache.jmeter.testelement.property.MultiProperty.<init>(MultiProperty.java:36) ~[ApacheJMeter_core-4.0.jar:4.0 r1823414]
        at org.apache.jmeter.testelement.property.TestElementProperty.<init>(TestElementProperty.java:31) ~[ApacheJMeter_core-4.0.jar:4.0 r1823414]
        at org.apache.jmeter.config.Arguments.addArgument(Arguments.java:119) ~[ApacheJMeter_core-4.0.jar:4.0 r1823414]
        at com.loadium.postman2jmx.model.jmx.JmxHTTPSamplerProxy.newInstance(JmxHTTPSamplerProxy.java:88) ~[Postman2Jmx.jar:?]
        at com.loadium.postman2jmx.builder.JmxRawBodyBuilder.buildJmxBody(JmxRawBodyBuilder.java:18) ~[Postman2Jmx.jar:?]
        at com.loadium.postman2jmx.builder.AbstractJmxFileBuilder.buildJmxFile(AbstractJmxFileBuilder.java:62) ~[Postman2Jmx.jar:?]
        at com.loadium.postman2jmx.builder.JmxFileBuilder.build(JmxFileBuilder.java:10) ~[Postman2Jmx.jar:?]
        at com.loadium.postman2jmx.app.Postman2Jmx.main(Postman2Jmx.java:35) [Postman2Jmx.jar:?]

Thank you!

PATCH requests have missing body

If a PATCH request has a body within Postman, it is not carried over to the jmx file.

It seems this is because there is no PATCH in this condition ->

if (HttpMethod.POST.equalsIgnoreCase(httpSamplerProxy.getMethod()) || HttpMethod.PUT.equalsIgnoreCase(httpSamplerProxy.getMethod()) || HttpMethod.DELETE.equalsIgnoreCase(httpSamplerProxy.getMethod())) {

The PATCH was introduced in Java WS RS API v2.1 -> https://javaee.github.io/javaee-spec/javadocs/javax/ws/rs/HttpMethod.html

I can see from the pom.xml there is a dependency on jMeter v4.0 which refers to Javax WS RS API v2.0.1.

Is there are any plans to have the dependency of jMeter changed to a newer version? I can raise a PR using a newer version of jMeter or a PR using jMeter v4 with a string constant for the PATCH in the above line.

ClassNotFoundException

Hi I've been trying to use your tool but I ran into this error when using $ java -jar Postman2Jmx.jar my_postman_collection.json my_jmx_file.jmx

Exception in thread "main" java.lang.NoClassDefFoundError: org/slf4j/LoggerFactory
        at com.loadium.postman2jmx.app.Postman2Jmx.<clinit>(Postman2Jmx.java:15)
Caused by: java.lang.ClassNotFoundException: org.slf4j.LoggerFactory
        at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581)
        at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
        ... 1 more

with java 14 and 11, and Maven 3.8.3, on windows and wsl

Any idea what is happening ? Thanks !

log4j vuln

I was flagged to this as the version included in the pom.xml is a vulnerable version of log4j.core.

I upgraded my xml to log4j-slf4j-impl = 2.21.1 and it does compile, i haven't tested it yet, but it should be fine I'd imagine.

I encountered some problems

After the compilation is completed, I encountered some problems when running and I don't know what to do.
Exception in thread "main" java.lang.ExceptionInInitializerError at com.thoughtworks.xstream.XStream.setupConverters(XStream.java:989) at com.thoughtworks.xstream.XStream.<init>(XStream.java:592) at com.thoughtworks.xstream.XStream.<init>(XStream.java:514) at com.thoughtworks.xstream.XStream.<init>(XStream.java:483) at com.thoughtworks.xstream.XStream.<init>(XStream.java:429) at com.thoughtworks.xstream.XStream.<init>(XStream.java:382) at org.apache.jmeter.save.SaveService$XStreamWrapper.<init>(SaveService.java:82) at org.apache.jmeter.save.SaveService$XStreamWrapper.<init>(SaveService.java:80) at org.apache.jmeter.save.SaveService.<clinit>(SaveService.java:113) at com.loadium.postman2jmx.builder.AbstractJmxFileBuilder.buildJmxFile(AbstractJmxFileBuilder.java:106) at com.loadium.postman2jmx.builder.JmxFileBuilder.build(JmxFileBuilder.java:10) at com.loadium.postman2jmx.app.Postman2Jmx.main(Postman2Jmx.java:35) Caused by: java.lang.reflect.Inam.XStream.<init>(XStream.java:429) at com.thoughtworks.xstream.XStream.<init>(XStream.java:382) at org.apache.jmeter.save.SaveService$XStreamWrapper.<init>(SaveService.java:82) at org.apache.jmeter.save.SaveService$XStreamWrapper.<init>(SaveService.java:80) at org.apache.jmeter.save.SaveService.<clinit>(SaveService.java:113) at com.loadium.postman2jmx.builder.AbstractJmxFileBuilder.buildJmxFile(AbstractJmxFileBuilder.java:106) at com.loadium.postman2jmx.builder.JmxFileBuilder.build(JmxFileBuilder.java:10) at com.loadium.postman2jmx.app.Postman2Jmx.main(Postman2Jmx.java:35) Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make field private final java.util.Comparator java.util.TreeMap.comparator accessible: module java.base does not "opens java.util" to unnamed module @21a947fe at java.base/java.lang.reflecccessibleObjectException: Unable to make field private final java.util.Comparator java.util.TreeMap.comparator accessible: module java.base does not "opens java.util" to unnamed module @21a947fe at java.base/java.lang.reflect.AccessibleObject.throwInaccessibleObjectException(AccessibleObject.java:391) at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:367) at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:315) at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:183) at java.base/java.lang.reflect.Field.setAccessible(Field.java:177) at com.thoughtworks.xstream.core.util.Fields.locate(Fields.java:40) at com.thoughtworks.xstream.converters.collections.TreeMapConverter.<clinit>(TreeMapConverter.java:50) ... 12 more

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.