Linux

Ubuntu vpn connects successfully and shortly thereafter fails – network traffic stops – either VPN and local network

I’ve started to use Ubuntu for my job needs and experienced first pretty annoying challenge with VPN connection. I’m using openvpn client with network manager. After successfull connect to VPN server I can use local and remote networks with no problem. After a while – like 1 -10 minutes , sometimes a bit longer up to couple hours or sometimes…

Continue Reading

ADF

ADF how to stretch table vertically and horizontally?

How to stretch ADF table vertically to fill maximum available vertical space in browser? Answer: Put table into af:panelStretchLayout component center facet. Put dimensionsFrom=”parent” attribute into af:panelStretchLayout (parent of af:panelStretchLayout component must stretch its children) How to stretch ADF table horizontally to fill maximum available horizontal space in browser? Answer: Put table into af:panelStretchLayout component center facet. Add styleClass=”AFStretchWidth” attribute to af:panelStretchLayout Example:   <af:panelStretchLayout…

Continue Reading

ADF, ADF Exceptions

ADF java.lang.ClassCastException: …ViewRowImpl cannot be cast to …ViewRow ?

For example: java.lang.ClassCastException: model.DepartmentsViewRowImpl cannot be cast to model.common.DepartmentsViewRow JDeveloper, when generating View Object Row client interface sometimes goes wrong with class definition. Such error can be displayed when implementation of class is not defined. In particular error sample –  “implements DepartmentsViewRow” is missing in DepartmentsViewRowImpl class: public class DepartmentsViewRowImpl extends ViewRowImpl implements DepartmentsViewRow { … }

ADF, Database, SQL and PL/SQL

ADF method for calling DB procedures, executing other SQL statements with input and output parameters

How to call DB procedure with input and output parameters. Here I provide an example of ADF method which can be used with any number of in/pout parameters used in any order:     public void runStatement(String stt, boolean commit, ArrayList<Map<String, Object>> pars) {                  CallableStatement st = this.getDBTransaction().createCallableStatement((stt), 0);      …

Continue Reading

ADF

How to output text with line breaks in ADF ?

If we use regular “af:outputtext” component to print text with line breaks (new line symbols like “n” or  “rn”)  in ADF – we don’t succeed. Text is displayed in one line regardless of those symbols. Instead we need to use  “af:outputFormatted” component. But it is not enough. While it does not understand “n” or “rn” symbols, we need to use HTML…

Continue Reading

ADF

How to get LOV value instead of index when it is used in “selectOneChoice” component in the table row?

When using LOV’s, a common issue in ADF is to get selected value instead of index when LOV is used to render for example “selectOneChoice” component. I’ve faced it when “selectOneChoice” was used in table. That means every row in table can have different selection of LOV values. Thus we can’t rely on iterators current row and simply to access…

Continue Reading

ADF, ADF Exceptions

JBO-25058: Definition vc_temp_1 of type Variable is not found in …

“JBO-25058: Definition vc_temp_1 of type Variable is not found in …”. What can be the reason? ADF creates/reuses application module (AM) instance for each user request. It is passivated (saved) after each HTTP request (if configured accordingly). When in application there are used some queries with view criteria, filter variables are passivated  for according AM as well. During the next…

Continue Reading