JBoss allocated sequences wrong and were not sync
When i used JBoss 5.1.0 and PostgreSql database and tried to insert / persist a row in database.
Persisted row contained id which was allocated 50 or 250 bigger that sequence which is created for that table and entity.
Suddenly i noticed that entity and sequence were not sync.
Annotation parameter allocationSize and tmp folder remove helped.
@SequenceGenerator(name = “gen_name”, sequenceName = “seq_name”, allocationSize = 1)
Remove:
jboss_5.1.0.GA\server\default\tmp
jboss_5.1.0.GA\server\default\work
org.hibernate.ejb.HibernatePersistence cannot be cast to javax.persistence.spi.PersistenceProvider
server\default\deployers\ear-deployer-jboss-beans.xml
<property name=”isolated”>true</property> -> <property name=”isolated”>false</property>
EARStructureDeployer is already installed.
If you’re using JBoss 6.0.0 in Eclipse Helios: double-click your server, go to the “Deployment” tab, choose “Use the JBoss deploy folder” and check the “Deploy projects as compressed archives”.
OracleXETNSListener system error 1067 has occurred
Problem, this error: System error 1067 has occurred when you’re trying to: net start OracleXETNSListener
Solution:
1. Drink a cup of coffee
2. Make sure you’re not using two separate internet connections e.g. a WLAN + Wired Connection
3. If you are turn off the WLAN or which ever you prefer
4. ????
5. Profit.
Hello World. Goodbye Vagina.
class Hello {
public static void main(String[] args) {
System.out.println(“Hello World. Goodbye Vagina”);
}
}
SVN conflict
Let’s say you and your colleague are editing a document at the same time. Then the other person saves and commits and there’s a conflict.
Now there are three files in SVN:
OriginalFile.doc
OriginalFile.doc.r20501
OriginalFile.doc.r20502
The last one contains the changes the other person made and committed. What you should do in this situation is:
1. Backup your own copy
2. Revert the file in SVN
3. Update the file in SVN
4. Then you could put locks on for future situations like this
This is done with Tortoise SVN as follows:
a) Select the file
b) Choose ‘Tortoise SVN’
c) ‘Properties’
d) Then click ‘New’ and select ‘svn:needs-lock’
e) Then input “*” without the quotes into the ‘Property Value’ field and press ‘Ok’
5. After the locks make your changes (you have to check them from your backup)
6. Save and commit
Google’s new search design sucks
Thanks Google for forcing me to change to Altavista again
It was fun while it lasted.. the last 10 years. Although I have to say I love the wonder wheel
Required file or directory ‘config/config.xml’ cannot be found.
Error: Path ‘x:\oracle\Middleware\xxx\domains’ is not a valid WebLogic domain. Required file or directory ‘config/config.xml’ cannot be found.
Solution: Go one step further, either choose the domain you’ve created under this folder or create a new domain.
Web Logic problems with New Server
Error: The path does not contain a valid WebLogic Server install.
Solution: Your server’s version and eclipse’s version of it do not match. Update your Eclipse if your server is recently downloaded and Eclipse was a package download like this: http://www.oracle.com/technology/software/products/oepe/oepe_11114.html.
So the solution is:
1. Start Eclipse
2. Help – Instal New Software
3. Choose ‘Add’
4. Provide a name (can be anything)
5. Paste this to the URL: http://download.oracle.com/otn_software/oepe/ganymede
6. Install
7. Let Eclipse restart and when adding ‘new server’ it should now work
8. At the time of writing Oracle WebLogic Server 11gR1 Patchset 2 provided the correct location for the files needed here.