[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14698237#comment-14698237 ] ASF subversion and git services commented on SOLR-7859: --- Commit 1696037 from [~andyetitmoves] in branch 'dev/branches/branch_5x' [ https://svn.apache.org/r1696037 ] SOLR-7859: Clamp down on use of System.currentTimeMillis Merges r1694798, r1695173 from trunk - Use RTimer where currentTimeMillis is used for timing - Abstract out a new class TimeOut for when currentTimeMillis/nanoTime is used to timeout operations. - Used `new Date()` in some cases where that is the logical intent. - Deprecated a couple of APIs which were publicly exposing epoch time, in favour of Date objects to make the intent clearer. - A couple of cases had currentTimeMillis in dead code. - In some cases where currentTimeMillis was used to just generate a name, used nanoTime instead (really it should be some sequence/random number in such a case). - In some other cases where stamps were used for SQL queries, HTTP headers, comparing against data in external files, ZK etc., used SuppressForbidden. - Also currently allow the use of currentTimeMillis in commit data, this is then used in replication – this is concerning since absolute times are being compared, but that can be dealt with separately. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14698232#comment-14698232 ] Ramkumar Aiyengar commented on SOLR-7859: - bq. There are also a couple of cases where the usage is suspect, but I haven't got to it as yet. One is around stats, but the more worrying thing is that we use the wall time recorded as commit data on a commit to check if replication needs to be done. In IndexFetcher, there is this code: I have raised SOLR-7932 for this.. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14680841#comment-14680841 ] Ramkumar Aiyengar commented on SOLR-7859: - Thanks for the offer Erik. This commit should hopefully address Uwe's post.jar concern. I have also now reverted your bin/post commit as it should not be needed any longer (and per my smoke test with the tool), but let me know if you see otherwise.. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14680835#comment-14680835 ] ASF subversion and git services commented on SOLR-7859: --- Commit 1695175 from [~andyetitmoves] in branch 'dev/trunk' [ https://svn.apache.org/r1695175 ] SOLR-7859: Revert r1694888 to add SolrJ to the path for bin/post, should not be needed any longer > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14680821#comment-14680821 ] ASF subversion and git services commented on SOLR-7859: --- Commit 1695173 from [~andyetitmoves] in branch 'dev/trunk' [ https://svn.apache.org/r1695173 ] SOLR-7859: Add RTimer classes to post.jar > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14680548#comment-14680548 ] Erik Hatcher commented on SOLR-7859: +1 If you need any help or want me to tackle it say the word. It looks like it'd be as easy as adding RTimer (and any other classes) to build.xml: {code} {code} adjusting includes to add ",org/apache/solr/util/RTimer*.class" > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14680499#comment-14680499 ] Ramkumar Aiyengar commented on SOLR-7859: - [~ehatcher], I have already committed the RTimer refactoring, so the SolrJ dep is no longer needed. The addition of RTimer to post.jar is a one line fix, which I will soon add, so no reversion should be necessary (would be simpler than that really). I have raised SOLR-7910 for the modularization, that applies even if post.cmd is created, as we can't assume that all the dependencies of solr-core are available to use. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14680474#comment-14680474 ] Erik Hatcher commented on SOLR-7859: RTimer and SimplePostTool are both in solr-core JAR at least, so java -jar dist/solr-core...jar SimplePostTool... will still do the trick. I think we just rollback the SPT changes per Uwe above and keep it simple. post.jar is eventually going to go away and be replaced by a bin/post(.cmd) script that can take advantage of SolrCloud, etc and will be utilizing the full capabilities of Solr's indexing facilities; we can then rely on JAR dependencies. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14680469#comment-14680469 ] Uwe Schindler commented on SOLR-7859: - bq. (If this is really a requirement, ideally SPT should move outside solr-core to a separate place where this requirement can be verified at compile time, though I find my build-system-fu lacking to do that.. +1 > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679432#comment-14679432 ] Ramkumar Aiyengar commented on SOLR-7859: - On second thought, I might still need to change the post.jar generation in solr/build.xml to include RTimer.class to satisfy Uwe's requirement. (If this is really a requirement, ideally SPT should move outside solr-core to a separate place where this requirement can be verified at compile time, though I find my build-system-fu lacking to do that..) > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679415#comment-14679415 ] Ramkumar Aiyengar commented on SOLR-7859: - Committed SOLR-7902. I haven't tried as yet, but we should be able to revert the post.jar change.. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679363#comment-14679363 ] Ramkumar Aiyengar commented on SOLR-7859: - Created SOLR-7902 to split out RTimer. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679347#comment-14679347 ] Ramkumar Aiyengar commented on SOLR-7859: - bq.let SimplePostTool use System.currentTimeMillies, add @SuppressForbidden You can use nanoTime without RTimer anyway. But hold off in any case.. I am anyway making a change to RTimer to break the NamedList dependency, RTimer is now used in many more places, and the child timer functionality is used in only one place. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679188#comment-14679188 ] Erik Hatcher commented on SOLR-7859: [~thetaphi] oh, good points - I concur - let's switch it back to no dependencies on SimplePostTool for now. And maybe it's time to get Windows support... at least a very simple `bin/post.cmd` that just delegates to post.jar, allowing an "interface" to posting content that we can evolve in the future. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679185#comment-14679185 ] Uwe Schindler commented on SOLR-7859: - My personal suggestion/opinion is: - let SimplePostTool use System.currentTimeMillies - add @SuppressForbidden It is very important to keep post.jar working standalone. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679184#comment-14679184 ] Uwe Schindler commented on SOLR-7859: - But this fix still breaks post.jar if used alone. It is still often used, e.g. on windows. If you do {{java -jar post.jar}}, this fails now. We have no windows shell script at the moment. In my opinion, we should make post.jar working on its own and also write a test for that. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679145#comment-14679145 ] Ramkumar Aiyengar commented on SOLR-7859: - Thanks Erik! > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679140#comment-14679140 ] Erik Hatcher commented on SOLR-7859: Fixed bin/post on trunk. If this gets ported to 5x, don't forget the bin/post fix too. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679139#comment-14679139 ] ASF subversion and git services commented on SOLR-7859: --- Commit 1694888 from [~ehatcher] in branch 'dev/trunk' [ https://svn.apache.org/r1694888 ] SOLR-7859: Fix bin/post to rely on SolrJ for RTimer use > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679137#comment-14679137 ] Erik Hatcher commented on SOLR-7859: This commit broke bin/post, which relies on SimplePostTool. The issue is that RTimer refers to NamedList which isn't in the classpath used by the SimplePostTool startup: {code} $ bin/post -c files ~/Documents java -classpath /Users/erikhatcher/dev/lucene-trunk/solr/dist/solr-core-6.0.0-SNAPSHOT.jar -Dauto=yes -Dc=files -Ddata=files -Drecursive=yes org.apache.solr.util.SimplePostTool /Users/erikhatcher/Documents/Lucidworks/ SimplePostTool version 5.0.0 Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/solr/common/util/NamedList at org.apache.solr.util.SimplePostTool.execute(SimplePostTool.java:176) at org.apache.solr.util.SimplePostTool.main(SimplePostTool.java:167) {code} The best fix is probably to have bin/post also include the SolrJ library. And yes, there needs to be a test for bin/post - created SOLR-7901 for this task. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14662982#comment-14662982 ] ASF subversion and git services commented on SOLR-7859: --- Commit 1694798 from [~andyetitmoves] in branch 'dev/trunk' [ https://svn.apache.org/r1694798 ] SOLR-7859: Clamp down on use of System.currentTimeMillis - Use RTimer where currentTimeMillis is used for timing - Abstract out a new class TimeOut for when currentTimeMillis/nanoTime is used to timeout operations. - Used `new Date()` in some cases where that is the logical intent. - Deprecated a couple of APIs which were publicly exposing epoch time, in favour of Date objects to make the intent clearer. - A couple of cases had currentTimeMillis in dead code. - In some cases where currentTimeMillis was used to just generate a name, used nanoTime instead (really it should be some sequence/random number in such a case). - In some other cases where stamps were used for SQL queries, HTTP headers, comparing against data in external files, ZK etc., used SuppressForbidden. - Also currently allow the use of currentTimeMillis in commit data, this is then used in replication -- this is concerning since absolute times are being compared, but that can be dealt with separately. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar >Assignee: Ramkumar Aiyengar > Attachments: SOLR-7859.patch, SOLR-7859.patch, SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (SOLR-7859) Clamp down on use of System.currentTimeMillis
[ https://issues.apache.org/jira/browse/SOLR-7859?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14653491#comment-14653491 ] Ramkumar Aiyengar commented on SOLR-7859: - Updated patch, now fixes a few places, removes use of core open timestamp for caching purposes in join queries in favour of nanoTime. > Clamp down on use of System.currentTimeMillis > - > > Key: SOLR-7859 > URL: https://issues.apache.org/jira/browse/SOLR-7859 > Project: Solr > Issue Type: Improvement >Reporter: Ramkumar Aiyengar > Attachments: SOLR-7859.patch > > > We did one round of this in SOLR-5734, but more places seem to keep cropping > up. We should do one more round, and start whitelisting places which really > need it using forbidden-apis. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org