Программисты JAVA общаются здесь
-
Anonymous
Соединение oracle.jdbc.driver.T4CConnection@73e0fb8c помечено как нарушенное из-за SQLSTATE(08003), ErrorCode(17008)
Сообщение
Anonymous »
Код: Выделить всё
@Service
public class StudentService {
@Autowired
private StudentRepository studentRepository;
public void enrollStudents(List students) {
//Calling 1st method (verification)
studentRepository.performBackgroundVerification(students);
//Calling 2nd method (enroll)
studentRepository.enrollStudents(students);
}
}
@Repository
public class StudentRepository {
public void performBackgroundVerification(List students) throws Exception {
Connection wrappedConnection = null;
OracleConnection oracleConnection = null;
try {
//Get Wrapped Connection
wrappedConnection = jdbcTemplate.getDataSource().getConnection();
//Get Oracle Connection
oracleConnection = wrappedConnection.unwrap(OracleConnection.class);
//Create Oracle Object(typ_student_obj")
Struct[] studentStruct = new Struct[students.size()];
for(int i=0; i
Подробнее здесь: [url]https://stackoverflow.com/questions/79158299/connection-oracle-jdbc-driver-t4cconnection73e0fb8c-marked-as-broken-because-of[/url]
1730796450
Anonymous
[code]@Service
public class StudentService {
@Autowired
private StudentRepository studentRepository;
public void enrollStudents(List students) {
//Calling 1st method (verification)
studentRepository.performBackgroundVerification(students);
//Calling 2nd method (enroll)
studentRepository.enrollStudents(students);
}
}
@Repository
public class StudentRepository {
public void performBackgroundVerification(List students) throws Exception {
Connection wrappedConnection = null;
OracleConnection oracleConnection = null;
try {
//Get Wrapped Connection
wrappedConnection = jdbcTemplate.getDataSource().getConnection();
//Get Oracle Connection
oracleConnection = wrappedConnection.unwrap(OracleConnection.class);
//Create Oracle Object(typ_student_obj")
Struct[] studentStruct = new Struct[students.size()];
for(int i=0; i
Подробнее здесь: [url]https://stackoverflow.com/questions/79158299/connection-oracle-jdbc-driver-t4cconnection73e0fb8c-marked-as-broken-because-of[/url]