How to control the session timeout is 30 sec in the BlazeDS? - flex3

dear friends, I didn't find how to set the session timeout less than 1 min in BlazeDS, web.xml 's timeout at least 1 min , how can I set the time less than 1 min , thanks a lot.

You can set the session timeout in the web.xml:
<session-config>
<session-timeout>1</session-timeout>
</session-config>
However the value is in minutes. So I don't think you can go below 1 minute.

You may try HttpSession's setMaxInactiveInterval(),
for instance in sessionCreated() method in custom HttpSessionListener (you can specify your listener class in web.xml)

Related

Catchpoint pause vs. waitForNoRequest - What's the difference?

I have a test that was alerting because it was taking extra time for an asset to load. We changed from waitForNoRequest to a pause (at Catchpoint's suggestion). That did not seem to have the expected effect of waiting for things to load. We increased the pause from 3000 to 12000 and that helped to allow the page to load and stop the alert. We noticed some more alerts, so I tried to increase the pause to something like 45000 and it would not allow me to pause for that long.
So the main question here is - what functionality does both of these different features provide? What do I gain by pausing instead of waiting, if anything?
Here's the test, data changed to protect company specific info. Step 3 is where we had some failures and we switched between pause and wait.
// Step - 1
open("https://website.com/")
waitForNoRequest("2000")
click("//*[#id=\"userid\"]")
type("//*[#id=\"userid\"]", "${username}")
setStepName("Step1-Login-")
// Step - 2
clickMouseAndWait("//*[#id=\"continue\"]")
waitForVisible("//*[#id=\"challenge-password\"]")
click("//*[#id=\"challenge-password\"]")
type("//*[#id=\"challenge-password\"]", "${password}")
setStepName("Step2-Login-creds")
// Step - 3
clickMouseAndWait("//*[#id=\"signIn\"]")
setStepName("Step3-dashboard")
waitForTitle("Dashboard")
waitForNoRequest("3000")
click("//*[#id=\"account-header-wrapper\"]")
waitForVisible("//*[#id=\"logout-link\"]")
click("//*[#id=\"logout-link\"]")
// Step - 4
clickAndWait("//*[text()=\"Sign Out\"]")
waitForTitle("Login - ")
verifyTextPresent("You have been logged out.")
setStepName("Step5-Logout")
Rachana here, I’m a member of the Technical Service Team here at Catchpoint, I’ll be happy to answer your questions.
Please find the differences below between waitForNoRequest and Pause commands:
Pause
Purpose: This command pauses the script execution for a specified amount of time, whether there are HTTP/s requests downloading or not. Time value is provided in milliseconds, it can range between 100 to 30,000 ms.
Explanation: This command is used when the agent needs to wait for a set amount of time and this is not impacted by the way the requests are loaded before proceeding to the next step or command. Only a parameter is required for this action.
WaitForNoRequest
Purpose: This commands waits for a specified amount of time, when there was no HTTP/s requests downloading. The wait time parameter can range between 1,000 to 5,000 ms.
Explanation: The only parameter for this action is a wait time. The agent will wait for that specified amount of time before moving onto the next step/command. Which will, in return, allow necessary requests more time to load after document complete.
For instance when you add waitforNoRequest(5000), initially agent waits 5000 ms after doc complete for any network activity. During that period if there is any network activity, then the agent waits another 5000 ms for the next network activity to end and the process goes on until no other request loads within the specified timeframe(5000 ms).
A pause command with 12000 ms, gives exactly 12 seconds to load the page. After 12 seconds the script execution will continue to next command no matter the page is loaded or not.
Since waitForNoRequest has a max time value of 5000 ms, you can tell the agent to wait for a gap of 5 seconds when there is no network activity. In this case, the page did not have any network activity for 3 seconds and hence proceeded to the next action. The page was not loaded completely and the script failed.
I tried to increase the pause to something like 45000 and it would not allow me to pause for that long.
We allow a maximum of 30 seconds pause time hence 45 seconds will not work.
Please reach out to our support team and we’ll be glad to connect you with our scripting SMEs and help you with any scripting needs you might have.

What is the maximum possible Apache HTTP TimeOut directive?

What is the maximum possible value that Apache2 Web Server allows for it's TimeOut directive in your httpd.conf or apache2.conf (in server config or vhost config) without failing back to the default value?
EDIT: To clarify, what I mean by 'failing back to the default value'.
It appears that when exceeding the upper bound of the directive, the value defining the TimeOut will revert back to 300. An example of this would be setting the TimeOut to 1800 (seconds), the server will continue to keep the request alive for 30 minutes succesfully. Whereas if you were to set the TimeOut to 31536000 (seconds) or 1 year, the server will revert or fail back to the default value of 300 (seconds) and only keeping the request alive for 5 minutes.
References:
http://httpd.apache.org/docs/2.0/mod/core.html#timeout
The default is set to 300 (seconds)
Though I am not sure I understand what you mean when you say - "without failing back to default value?", I am assuming that you are trying to determine the upper bound for Apache's Timeout directive. I dont believe org.apache.hc.core5.util.Timeout enforces an upper bound on its value. If you look at the source for Timeout, you will notice that timeout parameter values are Java longs. For example -
public static Timeout of(final long duration, final TimeUnit timeUnit) {
return new Timeout(duration, timeUnit);
}
So I believe that the directive's upper bound theoretically is the upper bound for Java long.
That said, please clarify what you mean by - "without failing back to default value?"

am not able to configure readTimeout to be more than 60 sec in karate

One of my api's take more than 2 mins ( i know it's bad response time) to respond and am using karate to test it. I tried to increase the default 30 sec time by * configure readTimeout = 90000 but it still only waits for 60 sec. am using karate v 0.7.0. Any suggestions?
You can try switching to karate-jersey from karate-apache or vice-versa. Also try the other connectTimeout setting. Else, upgrade to 0.9.1, in case this bug-fix is involved: https://github.com/intuit/karate/issues/586

How to disable bukkit server auto-disabling?

Hello I wanted to debug some of my bukkit plugins, but the problem is I can do brakepoint for max of 1 min, because after this time server auto-stops how can I disable it?
Minecraft's server.properties defines how long a tick can be before shutting down
max-tick-time=60000
Increasing this should let you pause the tick for a longer period of time
The time is in ms, so for a 1 hour pause use 1*60*60*1000=3600000
max-tick-time=3600000
If you wish to disable the feature entirely, -1 can be used
max-tick-time=-1

Reducers failing

We are using 3 cluster machine and mapreduce.tasktracker.reduce.tasks.maximum property is set to 9. When I set no of reducer is equal to or less than 9 job is getting succeeded but if I set greater than 9 then it is failing with the exception "Task attempt_201701270751_0001_r_000000_0 failed to ping TT for 60 seconds. Killing!". Can any one guide me what will be the problem
There seem to be some bug in hadoop -0.20.
https://issues.apache.org/jira/browse/MAPREDUCE-1905 (for reference ).
Can you please try to increase the task timeout ?
(mapreduce.task.timeout to a higher value ) ( 0 will disable the timeout )